[Gc] Re: Problems with GC_size_map

Ludovic Courtès ludo at gnu.org
Mon Feb 1 15:19:43 PST 2010


Hello,

Juan Jose Garcia-Ripoll
<juanjose.garciaripoll at googlemail.com> writes:

> On Mon, Feb 1, 2010 at 4:05 PM, Juan Jose Garcia-Ripoll <
> juanjose.garciaripoll at googlemail.com> wrote:
>
>> * I also played with custom marking procedures to avoid the bitmap, but I
>> did not manage to get it working. Somehow the mark code got stuck. I also
>> read the documentation and says it is not recommended to use custom marking
>> because code is slow due to lack of inlining. Is this true, or are there
>> simple examples showing how to properly use this technique?
>>
>
> I forgot to mention one thing. This implementation uses an interpreter stack
> (not native, C stack) and several other stacks that may get rather large.
> The garbage collector is configured not to scan DLLs, and the set of roots
> is cleared after initialization. All roots are identified by our
> implementation using a custom value of GC_push_other_roots. This gains us
> that not all the stack is scanned, only the part that is used by the
> interpreter.

In GNU Guile we use a custom mark procedure to achieve this, as was
suggested by... you.  :-)

(See
<http://thread.gmane.org/gmane.comp.programming.garbage-collection.boehmgc/3001>.)

> However I suspect we could do much better by identifying really which values
> in the interpreter stack are pointers and which are temporary data, such as
> integers, etc.

I’d expect it to be unlikely for an integer to be interpreted as a
pointer: there’s a non-zero type tag in the 3 LSBs and we disable
all-interior-pointers.

Thanks,
Ludo’.



More information about the Gc mailing list