[gclist] Two conservative collectors

Boehm, Hans hboehm@exch.hpl.hp.com
Fri, 19 Nov 1999 10:34:21 -0800


[Michael Spertus wrote:]

> Like you, I would be very surprised if debug info was good enough to 
> provide any help to the collector in garbage collecting the stack.
However, 
> the original idea of this thread (I'm not sure if it has changed :) was on

> trying to report on excess retention not to automatically eliminate it.
I thought it had changed.  That may explain some of the disagreements.

> I 
> would expect that debug info could be very useful on that score even if it

> is only "good enough for a debugger". Matt, how did you determine that the

> reports you were seeing came from holes in the stack and not temporaries
as 
> Hans suggests?
I didn't mean to suggest that.  My concern was that temporaries are hard to
locate
from debug information.

I agree that if a conservative collector retains extra memory, that's most
commonly
due to "stack holes".  That has also been my experience on the few occasions
I've looked at such things.  Fortunately, such retention is usually bounded
and
temporary.

The probability of such retention seems to be highly platform specific.
The less wasted space there is in stack frames, the better.  The Intel X86
architecture and ABIs actually seem to do quite well in this regard, both
because
frames tend to be relatively small, and becasue they tend to be aggressively
written.
Most of the RISC architectures do worse, since the ABIs are sloppier about
keeping stack
frames small.

Hans