RFR: Fix full gc with class unloading

Kelvin Nilsen kdnilsen at openjdk.java.net
Tue Sep 14 21:56:34 UTC 2021


On Mon, 13 Sep 2021 21:59:30 GMT, William Kemper <wkemper at openjdk.org> wrote:

>> This pull request fixes incompatibilities between Full GC and class unloading.  In particular, when degenerated GC upgrades to Full GC, it is important to change the generation to GLOBAL.  Otherwise, certain assertions related to class unloading fail.
>
> src/hotspot/share/gc/shenandoah/shenandoahControlThread.cpp line 591:
> 
>> 589:     assert(heap->cancelled_gc(), "Must have been cancelled");
>> 590:     check_cancellation_or_degen(gc.degen_point());
>> 591:     if (generation->generation_mode() == OLD) {
> 
> Is this ever true here? Old collections should go through the `service_concurrent_old_cycle` method.

I think you're right.  I had not understood all the control paths to this point.

-------------

PR: https://git.openjdk.java.net/shenandoah/pull/67


More information about the shenandoah-dev mailing list