Re: help with huge memory consumption??



On Mar 10, 6:30 pm, phil-news-nos...@xxxxxxxx wrote:

Comparing
threads and processes is more like comparing shipping the _same_ product
by overnight vs. by boat. There are fundamental differences. Some things
should not be shipped by some means. The eggs might break in airplanes.
Fresh fish might spoil shipped by truck. Certain hazardous material just
cannot be shipped by mail or courier. But that doesn't mean you can't
compare airplanes vs. boats vs. trucks vs. railroads vs. donkey backs.
By doing the comparisons you find out what may be impractical for some
things. You may find out which programs are impractical to do in threads
or in processes. But that's a result of comparison, not an excuse to
deny that comparison can even be done.

Exactly, and that is why I call foul every time the first thing
someone does when comparing the performance of a multi-thread to a
multi-process approach is compare the cost of creating a thread to the
cost of creating a process. In the list of relevant considerations, it
is maybe in the top 50 but probably not.

The viewpoint I am arguing against is:

It costs some time to create a process, and threads don't have that
time, so threads must be better.

And my response is that that when talking about the performance of a
multi-threaded approach versus a multi-process approach, it is
nonsensical to directly compare the cost of creating a thread to the
cost of creating a process. Only in the rare case where you had to
choose between creating one and creating the other precisely the same
number of times would that have any relevance, and that almost never
happens.

DS

.



Relevant Pages

  • Re: help with huge memory consumption??
    ... | Because thread creation is in no way analogous to process creation. ... So it's nonsensical to compare ... Linux clone() call is not too far from this. ... The cost of a thread ...
    (comp.os.linux.development.system)
  • Re: Quad Core PC for less than a Mac Mini
    ... A meaningless one when compared to computers. ... Cars are quite easy for a friend of mine to assemble, ... compare equals. ... home is an example of a cost avoidance of eating out. ...
    (comp.sys.mac.advocacy)
  • Re: help with huge memory consumption??
    ... Given a parallel task that can be done with threads, ... Just because design issues are different (they are for lots of choices ... | You cannot take two completely different programs and compare them by ... | looking at the cost of one operation that one does against some other ...
    (comp.os.linux.development.system)
  • Re: Quad Core PC for less than a Mac Mini
    ... A meaningless one when compared to computers. ... merely a reminder to compare likes to like. ... Because you do not properly recognize cost avoidances. ... a competitor's price to make my product's price look better. ...
    (comp.sys.mac.advocacy)
  • Re: Windows over Linux??
    ... You can't compare Ubuntu and XP in such a simple manner. ... it doesn't mean that won't cost any money over ... systems, Windows having such a big market share, is THE target. ...
    (microsoft.public.windowsxp.general)