guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GC ??


From: Matthias Koeppe
Subject: Re: GC ??
Date: Wed, 03 Dec 2003 11:44:22 +0100
User-agent: Gnus/5.090024 (Oort Gnus v0.24) Emacs/21.3.50 (usg-unix-v)

address@hidden writes:

> My question is still unasnwered.  Shouldn't the
> garbage collector attend all the globals and the
> recurse on the internal scm objects during the
> trace operation?

The garbage collector only scans the Scheme heap and the C/Scheme
stack, but neither the global C data nor the C heap.  I think the
rationale is that it would be very expensive to scan these memory
regions because they may be very large and contain only very few
Scheme objects.  Moreover, they may contain many "false pointers" that
look like Scheme objects, which would make garbage collection
ineffective. 

Therefore one needs to manually protect Scheme objects that are stored
in these memory regions from being garbage collected.

-- 
Matthias Koeppe -- http://www.math.uni-magdeburg.de/~mkoeppe




reply via email to

[Prev in Thread] Current Thread [Next in Thread]