Skip to content

Commit 7c173fd

Browse files
author
Xiaolong Peng
committedMar 4, 2025
8351077: Shenandoah: Update comments in ShenandoahConcurrentGC::op_reset_after_collect
Reviewed-by: wkemper, ysr
1 parent 96613cc commit 7c173fd

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed
 

‎src/hotspot/share/gc/shenandoah/shenandoahConcurrentGC.cpp

+3-5
Original file line numberDiff line numberDiff line change
@@ -1230,11 +1230,9 @@ void ShenandoahConcurrentGC::op_reset_after_collect() {
12301230

12311231
ShenandoahHeap* const heap = ShenandoahHeap::heap();
12321232
if (heap->mode()->is_generational()) {
1233-
// Resetting bitmaps of young gen when bootstrap old GC or there is preempted old GC
1234-
// causes crash due to remembered set violation, hence condition is added to fix the crash.
1235-
// Assuming bitmaps of young gen are not used at all after the cycle, the crash should not
1236-
// have happend, it seems to tickle a bug in remembered set scan. Root causing and fixing of the bug
1237-
// will be tracked via ticket https://bugs.openjdk.org/browse/JDK-8347371
1233+
// If we are in the midst of an old gc bootstrap or an old marking, we want to leave the mark bit map of
1234+
// the young generation intact. In particular, reference processing in the old generation may potentially
1235+
// need the reachability of a young generation referent of a Reference object in the old generation.
12381236
if (!_do_old_gc_bootstrap && !heap->is_concurrent_old_mark_in_progress()) {
12391237
heap->young_generation()->reset_mark_bitmap<false>();
12401238
}

0 commit comments

Comments
 (0)
Please sign in to comment.