Is the Right Tool a Matter of Preference?

A place to discuss the implementation and style of computer programs.

Moderators: phlip, Moderators General, Prelates

korona
Posts: 495
Joined: Sun Jul 04, 2010 8:40 pm UTC

Re: Is the Right Tool a Matter of Preference?

Postby korona » Thu Jul 26, 2012 4:19 pm UTC

EvanED wrote:
korona wrote:
EvanED wrote:Edit again First, the 70% measurement is for double the heap size of the explicitly-managed program; the intro doesn't say that, but the other two places do and that can be read off table 4.

Is for the double average heap size (the second column) but for roughly the same maximum heap size (the first column) i.e. the amount of memory required for GenMS. Since GenMS uses mark and sweep in the mature space I suspect that this is roughly the same amount required for manual allocation. The paper does not talk about the relation of minimal memory required by GenMS to the minimal memory required by manual allocation.

That's not my reading of table 4.

The caption says "The heap sizes are multiples of the minimum amount required to run with GenMS." That means that the first row is the minimum heap size for GenMS. I read the next column as showing the overhead in heap size relative to the manual memory manager -- 210%. That means that GenMS won't even run until you double the heap size relative to the manual allocator. This is consistent with figure 3 as well, which shows table 4 graphically: "Points in the graph represent the heap footprint (the x-axis) and runtime (y-axis) for the garbage collection algorithm relative to the explicit memory manager", and the first data point for GenMS is about x=2. It's also consistent with version of the sentence I quoted before that's in the abstract and conclusion: "with only twice as much memory, garbage collection degrades performance by nearly 70%" -- this matches table 4, where the heap size 1.00 (relative to the minimum that GenMS requires) corresponds to an overhead of 2x vs manual management and a runtime of 169%.

Your interpretation is indeed consistent with the sentence from the abstract. But that would mean GenMS requires twice as much memory as LEA which does not really make sense because GenMS is basically manual allocation for the large mature generation. The caption of table 4 also says "Geometric mean of memory footprints and runtimes for GenMS versus Lea", so I think they are comparing average footprint and not minimal heap size required for GenMS vs. Lea in column 2. EDIT: I think you're right and geometric mean means geometric mean over all benchmarks in this case. It is still surprising that GenMS needs so much memory. Does that imply that the young generation is as least as big as the mature one in their configuration?

sourmìlk wrote:Well, yeah. My point is just that, when a garbage collected language runs ten times slower, it's not appropriate to use that language. I really fail to see that controversy in that statement. I don't think there is one, I think people are miscommunicating.

I think the point of contention is just of whether a 10x slowdown is likely to happen in practice. I say that such situations are very rare, and it's usually more useful to worry about other things.

Yes that is exactly the controversy. My point is that the 10 times slowdown will never happen as it only happens if you're using more than 100% of all physical memory, which you would never do. My point is that you would decrease the maximal heap size of your collector and never extend it beyond the size of your physical memory. That way the slowdown will only be 70%.

User avatar
sourmìlk
If I can't complain, can I at least express my fear?
Posts: 6393
Joined: Mon Dec 22, 2008 10:53 pm UTC
Location: permanently in the wrong
Contact:

Re: Is the Right Tool a Matter of Preference?

Postby sourmìlk » Thu Jul 26, 2012 4:55 pm UTC

EvanED wrote:I think the point of contention is just of whether a 10x slowdown is likely to happen in practice. I say that such situations are very rare, and it's usually more useful to worry about other things.

Well in general, but not if you're in that situation. And I'm sure that is your stance, but I don't think anybody's actually said that. For example, Ben-Oni is making the argument that you should use garbage collected languages even in that situation.
Terry Pratchett wrote:The trouble with having an open mind, of course, is that people will insist on coming along and trying to put things in it.

Ben-oni
Posts: 278
Joined: Mon Sep 26, 2011 4:56 am UTC

Re: Is the Right Tool a Matter of Preference?

Postby Ben-oni » Thu Jul 26, 2012 9:30 pm UTC

sourmìlk wrote:
EvanED wrote:I think the point of contention is just of whether a 10x slowdown is likely to happen in practice. I say that such situations are very rare, and it's usually more useful to worry about other things.

Well in general, but not if you're in that situation. And I'm sure that is your stance, but I don't think anybody's actually said that. For example, Ben-Oni is making the argument that you should use garbage collected languages even in that situation.

I am?

User avatar
sourmìlk
If I can't complain, can I at least express my fear?
Posts: 6393
Joined: Mon Dec 22, 2008 10:53 pm UTC
Location: permanently in the wrong
Contact:

Re: Is the Right Tool a Matter of Preference?

Postby sourmìlk » Fri Jul 27, 2012 9:33 am UTC

Um yes, my understanding is that that is your argument. When I stated that the first time, you disagreed.
Terry Pratchett wrote:The trouble with having an open mind, of course, is that people will insist on coming along and trying to put things in it.


Return to “Coding”

Who is online

Users browsing this forum: No registered users and 4 guests