Re: concurrency, threads and objects




Robert Klemme wrote:
5ms as average starting time for a thread isn't really much.

That means windows can only create 400 threads in 2 seconds, compared to linux 2.6 which creates 100,000 threads in 2 seconds. hats a big difference. That makes me understand why people in this thread talks about the performance hit of having large number of threads.

We are, though, comparing c thread calls to java thread calls, even though java threads are native threads on both windows and linux in java 5.0
Additionally these numbers say nothing about execution efficiency of threads in windows compared to linux.

I will have a look at you program and run it on my computer, in both windows and linux, since there would be no no hardware difference. I never thought it might be that big a difference between linux and windows, actually I am not sure this difference can be correct. I know Ingo Molnar of the linux kernel team is really good when it comes this stuff, but microsoft can not be doing that bad here, we will see.

To test execution efficiency I will create a small test app which I will run on both systems as well, just to get that angle. I will post my results.

> While I do agree
that thought has to be given to issues of memory consumption and CPU usage during design of performance critical applications, overdoing it is certainly doing more harm than good. Considering the overhead of one object created per thread to be too much will definitively harm the design of the application. And this is even more so true in Java where the overhead of object creation on modern VM's is negligible.

I agree, it was an instinctive reaction that prompted me to start this thread and I decided I wanted to know the answer. I like to know the cost and consequence of doing things on one way compared to another, for future reference.

I would be very carefully carrying over knowledge from a C environment to a Java or other OO environment. While there are similarities and general principles one must be aware of the platform and adjust to its specifics.

I agree, but that does not preclude the chance that there might something that can be learned from other platforms.

tom
.



Relevant Pages

  • Re: Future of IT in Lebanon
    ... working knowledge of Indian programmers DNA, nor of their intuitive Java ... > So Longhorn is not an experiment and Linux is an experiment? ... another chapter in the Windows story, and the Microsoft marketing machine is ... > application opens, Check the about, it says Microsoft Visual Basic 6.3. ...
    (soc.culture.lebanon)
  • Re: PcLinux
    ... first instance, we use Java. ... Can't comment on Python because I've never used it. ... Postgresql running on linux works nicely. ... Returning to comments WRT the aesthetics of OS X vs Windows - it's a ...
    (rec.crafts.metalworking)
  • Re: OT: Spiegel-Online bei Heise
    ... Aber, wie schon gesagt, so simpel ist die Hardware heute ja nicht mehr, daß es mal eben mit ein paar inb/outb-Befehlen getan ist. ... Java ist in gewissen Bereichen etabliert, ... Wer Word/Excel/Powerpoint haben will, braucht Windows. ... und ein Linux für DSP von Freescale ...
    (de.comp.os.unix.linux.misc)
  • Re: OT: Linux builds
    ... But for now is there a good linux build for a relative technotard living in a windows based world. ... install the Gnome desktop or KDE 3.5.9.5 rather than KDE 4. ... Java 1.6 for 64-bit does not support javaws, and Java 1.7 IcedTea is still "preproduction" in Sun's definition and will not work with all Java that is out there. ...
    (alt.smokers.pipes)
  • Pfew! I am glad .NET exists... confessions of a MS immigrant.
    ... I used to be a die hard Linux ... When WinXP Professional came out using Windows became more fun but that is ... Java. ... it standalone (rather than within the IDE) then hell breaks lose. ...
    (microsoft.public.dotnet.framework.windowsforms)