RFR: JDK-8114823 - G1 doesn't honor request to disable class unloading
jesper.wilhelmsson at oracle.com
Thu Mar 31 13:51:11 UTC 2016
Please review this change to make the GCs disable class unloading if disabled on
the command line.
There are a few parts in this change:
1. The flag ClassUnloadingWithConcurrentMark was not set to false if
ClassUnloading was disabled on the command line. This is now done.
2. CMS was using CMSClassUnloadingEnabled instead of the more generic
ClassUnloadingWithConcurrentMark. I changed so that
ClassUnloadingWithConcurrentMark is used all over and CMSClassUnloadingEnabled
is only used as an alias when initializing the arguments. At some point it would
be nice to deprecate CMSClassUnloadingEnabled but it is a fairly well known flag
so that's not part of this change.
3. CMS, Serial, and PS did correctly disable class unloading when told so, but
the outermost code witch included some logging was still enabled making class
unloading output present in the log file. I changed so that this code is also
4. G1 did not disable class unloading during full GCs at all. This is now done.
Testing: I used SecureDBBTest.java as suggested in the bug while fixing to
verify that class unloading was happening before the fix and not after. I also
ran it through JPRT.
More information about the hotspot-gc-dev