This is the mail archive of the guile@cygnus.com mailing list for the guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: gc notes available



> But the assumption is that the page faults will be quite rare, no?
> MOst mutations occur in the youngest generation, and the older
> generations are static so that they don't need to be treated at every
> gc turn.
> 
> We would incur the function call overhead at every *potential*
> mutation of a older generation, not only at the *actual* mutations.

Yeah, that's a good point.  I wasn't thinking about that.

Assuming that a generation is, by definition, the smallest possible
unit of collection, you do have to protect all but the youngest
generation.

> I think the value is good enough.  Not the modified object needs to be
> in the root set, but the object that has a new reference to it.

But each generation has its own pointer of roots to be used when
collecting only younger generations.  Which root set does this pointer
get listed in?  Suppose I've got three generations:

0  youngest
1  young
2  old

And suppose the value being stored is a pointer to an object in
generation 0.  If the containing object is in generation 1, then I
must use the extra root pointer when collecting generation 0, but I
can (must?) ignore the extra root pointer when I collect generation 1
or 2.