[Gc] Problems with GC_size_map

Bruce Hoult bruce at hoult.org
Tue Feb 2 01:53:19 PST 2010

On Tue, Feb 2, 2010 at 10:42 PM, Juan Jose Garcia-Ripoll
<juanjose.garciaripoll at googlemail.com> wrote:
> On Tue, Feb 2, 2010 at 5:35 AM, Boehm, Hans <hans.boehm at hp.com> wrote:
>> You're using GC_MALLOC_WORDS in gc_inline.h?  The idea here was that you
>> supply a freelist array that is used for fast inline allocation of small
>> objects.  The fast path shouldn't access GC_arrays.  The slow path uses
>> function calls into the collector.  This code is also used by
>> thread-local-allocation, but otherwise may not be tremendously well tested.
> I have a stupid question. The tiny free list, does it have to be allocated
> as atomic or as ordinary? And from the header I understood there is no need
> for locking and can be used for thread-local allocation of data that is
> shared by all threads. Is this correct?

I would suspect that it should not be allocated by the GC at all, but
atomic uncollectible would be OK too.

More information about the Gc mailing list