harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ivan Volosyuk" <ivan.volos...@gmail.com>
Subject Re: [drlvm] Class unloading support
Date Tue, 31 Oct 2006 10:51:27 GMT
Robin, thank you for this information. I want to ask a few questions
to check that I understand you correctly.

On 10/31/06, Robin Garner <robin.garner@anu.edu.au> wrote:
> MMTk implements several algorithms for retaining the reachable objects
> in a graph and recycling space used by unreachable ones.  It relies on
> the host VM to provide a set of roots.  It supports several different
> semantics of 'weak' references, including but not confined to those
> required by Java.
> If you can implement class unloading using those (which the current
> proposal does), then MMTk can help.
> If you want to put a pointer to the j.l.Class in the object header, MMTk
> will not care, as it has no way of knowing.  If you put an additional
> pointer into the body of every object, then MMTk will see it as just
> another object to scan.

Does this mean that MMTk will not work with VM in which VTable pointer
(a pointer in object header) points to other heap object?

> Remember MMTk is a memory manager, not a Java VM!
> Conversely, supporting some exotic class unloading mechanism in MMTk
> shouldn't be hard and wouldn't deter me from trying it out.  If (as a
> wild idea) you wanted to periodically scan the heap, and count all
> references to each classloader, you could implement this with very
> little work as a TraceLocal object, and then extend the GC plan you
> wanted with an additional GC phase that would periodically do one of
> these scans after a major GC (for example).

This looks similar to approach #2 discussed here, agree?

Intel Enterprise Solutions Software Division

View raw message