RFR: 8312321: GenShen: Remembered set scan may encounter garbage objects

Kelvin Nilsen kdnilsen at openjdk.org
Thu Jul 20 03:04:20 UTC 2023


On Tue, 18 Jul 2023 21:56:20 GMT, William Kemper <wkemper at openjdk.org> wrote:

> During a global cycle, regions with no live objects may be reclaimed early (before evacuation). Once this happens, we _must_ coalesce and fill any dead objects in old regions because they may hold pointers into the reclaimed regions (even if the gc is cancelled before coalesce and fill). A subsequent scan of the remembered set may crash if it encounters these objects.

Marked as reviewed by kdnilsen (Committer).

src/hotspot/share/gc/shenandoah/shenandoahConcurrentGC.cpp line 230:

> 228:     // We chose not to evacuate because we found sufficient immediate garbage. Note that we
> 229:     // do not check for cancellation here because, at this point, the cycle is effectively
> 230:     // complete. If the cycle has been cancelled here, the control thread will detect it at

small typo: extra "at"

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

PR Review: https://git.openjdk.org/shenandoah/pull/297#pullrequestreview-1538342239
PR Review Comment: https://git.openjdk.org/shenandoah/pull/297#discussion_r1268877721


More information about the shenandoah-dev mailing list