Etienne Gagnon wrote:
OK.  My latest proposal (a few messages ago) was assuming that the
nursery was empty when the "end of epoch collection" is launched.

If it is not, you can do 2 things:

a) do a minor collection to empty it, or

b) i  - use a finalization-like list of references to class loader
        objects
   ii - launch gc, which might mark a previously unmarked vtable
   iii- do a finalization-like rescuing for resuscitated class loaders

"b)" should really have a minimal performance impact.  As for its
"apparent complexity", I would say that this is a non-issue; similar
code must already exist in drlvm for implementing finalization.

Just for clarification: "b)" implies a combined "nursery + mature space"
collection.

Actually, for the mature space part, you could get away with a smaller
collection if you premature all class loaders and classes to a specific
mature space area; the you only need to collect that space (in addition
to the nursery).

Etienne


This sounds rather 'stop the world' - while the barrier is more complicated I think it scales to concurrent collectors.

Also, don't forget an instance of a class in the nursery can pass a reference to its classloader to a mature-space object under suitably bizarre circumstances. I guess you could have a write barrier on the class metadata space ...

... an XOR barrier could actually be an interesting solution ... but I'm sure it won't be necessary.

--
Robin Garner
Dept. of Computer Science
Australian National University
http://cs.anu.edu.au/people/Robin.Garner/

Reply via email to