RFR: Correctly iterate references in humongous regions

Roman Kennke rkennke at redhat.com
Fri Mar 31 10:50:16 UTC 2017

The new marked_object_oop_iterate() does not correctly handle humongous
regions: for the humongous start region, it would iterate over all
references in the humongous array, even those in humongous
continuations, attempting to iterate humongous continuations would
crash. This patch makes oop* iteration using marked_object_oop_iterate()
consistent with ShenandoahHeapRegion::oop_iterate(): it iterates only
oop* that are within the region, even for humongous start and
continuation regions. This is important not only for consistency (with
SHR::oop_iterate()) and efficiency (allows to distribute iteration over
GC threads), but also for correctness: partial GC/connection matrix
tracks precisely which regions point to which, and only attempts to scan
root regions, even if they are interior in humongous arrays.

Tested by specjvm and hotspot_gc_shenandoah.



More information about the shenandoah-dev mailing list