RFR (S): 8011803: release_C_heap_structures is never called for anonymous classes.
David Holmes
david.holmes at oracle.com
Thu Apr 11 19:21:12 PDT 2013
Hi Coleen,
Can you clarify something for me please. ClassLoaderData::unload() is
what now cleans up the anonymous classes - correct? But
ClassLoaderData::unload() is only called when the ClassLoader is
unloaded - correct? And the whole point of anonymous classes is that
they get unloaded independent of the classloader lifecycle. Assuming I'm
correct so far it seems to me that if the classloader is never unloaded,
the anonymous classes still won't have release_C_heap_structures called.
And if it is unloaded it could be well after the classes were unloaded.
David
On 12/04/2013 6:52 AM, Coleen Phillimore wrote:
> Summary: Call this function from CLD::unload() now for anonymous classes.
>
> Anonymous classes aren't in the system dictionary so
> release_C_heap_structures isn't called for them if they are unloaded. I
> fixed this for jdk8 because they are in the class loader data graph but
> for jdk7, I don't know how to fix this. They are unloaded by being
> garbage collected after the references are dropped.
>
> Tested with ute tests vm.mvlm.testlist nsk.monitoring.testlist and
> jdk/test/java/lang/invoke tests.
>
> open webrev at http://cr.openjdk.java.net/~coleenp/8011803/
> bug link at http://bugs.sun.com/view_bug.do?bug_id=8011803
>
> Thanks,
> Coleen
More information about the hotspot-dev
mailing list