This is the mail archive of the
java-discuss@sourceware.cygnus.com
mailing list for the Java project.
Re: Array marking
- To: Bryce McKinlay <bryce at albatross dot co dot nz>
- Subject: Re: Array marking
- From: Jeff Sturm <jsturm at sigma6 dot com>
- Date: Fri, 28 Apr 2000 10:58:24 -0400
- CC: minyard at acm dot org, java-discuss at sourceware dot cygnus dot com, "Boehm, Hans" <hans_boehm at hp dot com>
- Organization: AppNet
- References: <3900EAAE.D9221332@albatross.co.nz> <m2ln1yx6eo.fsf@c469597-a.grlnd1.tx.home.com> <39091096.A6369275@albatross.co.nz>
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