RFR: 8369068: GenShen: Generations still aren't reconciled assertion failure [v2]

William Kemper wkemper at openjdk.org
Wed Oct 22 21:21:39 UTC 2025


On Wed, 22 Oct 2025 00:36:25 GMT, Y. Srinivas Ramakrishna <ysr at openjdk.org> wrote:

>> src/hotspot/share/gc/shenandoah/shenandoahFullGC.cpp line 358:
>> 
>>> 356:     assert(_from_region != nullptr, "must set before work");
>>> 357:     assert(_heap->marking_context()->is_marked(p), "must be marked");
>>> 358:     assert(!_heap->marking_context()->allocated_after_mark_start(p), "must be truly marked");
>> 
>> Why not `_generation->complete_marking_context()...` with the help of a `_generation` field kept in the object? It would make the idiom uniform and consistent across all these closures.
>
> Or like you did below at line 784, perhaps `_heap->global_generation()->complete_marking_context()...` stashed in local `_ctx` field ?

The context here is only used for the assertion. I'll add an `assert(_heap->global_generation()->is_marking_complete())`.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27703#discussion_r2453379755


More information about the shenandoah-dev mailing list