Array marking
Jeff Sturm
jsturm@sigma6.com
Fri Apr 28 07:24:00 GMT 2000
Bryce McKinlay wrote:
> - given that the first bit (ie the vtable pointer bit) of the mark
> descriptors generated by the compiler is currently allways `1',
> the gc may be trying to scan statically created vtables (?) -
> wasted cycles. This could easily be changed to allways be `0',
I take it "statically created vtables" implies native classes, not
interpreted (bytecode) classes here.
> but in that case:
> - the gc needs to know to mark the Class object pointed to by the
> first word of the vtable.
It should not be necessary to mark the Class object at all. A class may
not be collected before its classloader is collected. The system
classloader can never be collected. Therefore classes loaded by the
system classloader are never eligible for collection anyway. That
includes all native classes, right?
For this to work one of the GC roots must include all native classes, so
marking the class from the object vtable seems redundant.
--
Jeff Sturm
jsturm@sigma6.com
More information about the Java
mailing list