RFR: 8325808: GenShen: Move generational mode code out of shFullGC.cpp

William Kemper wkemper at openjdk.org
Mon Feb 26 21:40:56 UTC 2024


On Mon, 19 Feb 2024 17:40:32 GMT, Y. Srinivas Ramakrishna <ysr at openjdk.org> wrote:

>> This change reduces the differences from the upstream branch by moving large chunks of generational mode code into separate files.
>
> src/hotspot/share/gc/shenandoah/shenandoahFullGC.cpp line 183:
> 
>> 181:     // b. Cancel all concurrent marks, if in progress
>> 182:     if (heap->is_concurrent_mark_in_progress()) {
>> 183:       // TODO: Send cancel_concurrent_mark upstream? Does it really not have it already?
> 
> We have:
> 
> void ShenandoahHeap::cancel_concurrent_mark() {
>   _young_generation->cancel_marking();
>   _old_generation->cancel_marking();
>   _global_generation->cancel_marking();
> 
>   ShenandoahBarrierSet::satb_mark_queue_set().abandon_partial_marking();
> }
> 
> 
> whereas upstream has:
> 
>     // b. Cancel concurrent mark, if in progress
>     if (heap->is_concurrent_mark_in_progress()) {
>       ShenandoahConcurrentGC::cancel();
>       heap->set_concurrent_mark_in_progress(false);
>     }
> 
> 
> Should probably be reconciled and upstreamed if not here, then in a separate but linked CR.

We changed the behavior of cancellation somewhat for the generational mode. We essentially overloaded 'cancellation' to mean 'suspension' for old gen marking. I agree it needs to be reconciled, but I think it's outside the scope of this PR.

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

PR Review Comment: https://git.openjdk.org/shenandoah/pull/398#discussion_r1503332619


More information about the shenandoah-dev mailing list