RFR: Restore ShenandoahVerify functionality for generational mode

Roman Kennke rkennke at openjdk.java.net
Thu Mar 18 16:41:56 UTC 2021


On Thu, 18 Mar 2021 15:36:58 GMT, earthling-amzn <github.com+71722661+earthling-amzn at openjdk.org> wrote:

> ### Summary
> 1. Add remembered set to verifier roots for young generation collections
> 2. Don't follow pointers outside the generation during verify traversals
> 3. Verify generation's `used` value
> 4. Correct errors in computing a generation's `used` values
> 
> ### Testing
> 1. Dacapo suite completes without verification errors
> 2. hotspot_gc_shenandoah completes without verification errors

Very nice! Looks good except a few stylistic nits.
How far away is it from running all of hotspot_gc_shenandoah with added generational runners?

src/hotspot/share/gc/shenandoah/shenandoahHeapRegion.cpp line 828:

> 826: 
> 827:   UpdateCardValuesClosure update_card_values;
> 828:   ShenandoahGeneration *old_generation = heap->old_generation();

We usually use Type* var instead of Type *var notation.

src/hotspot/share/gc/shenandoah/shenandoahRootVerifier.cpp line 113:

> 111:   }
> 112: 
> 113:   ShenandoahHeap *heap = ShenandoahHeap::heap();

Same as above. Use ShenandoahHeap* heap. Occurs a few times in this file.

src/hotspot/share/gc/shenandoah/shenandoahScanRemembered.inline.hpp line 596:

> 594:   ShenandoahHeap* heap = ShenandoahHeap::heap();
> 595:   for (size_t i = 0, n = heap->num_regions(); i < n; ++i) {
> 596:     ShenandoahHeapRegion* region = heap->get_region(i);

And in this file too. Please check the whole change for this pattern ;-)

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

Marked as reviewed by rkennke (Reviewer).

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


More information about the shenandoah-dev mailing list