Skip to content

Commit 248aa50

Browse files
author
Thomas Schatzl
committed
8269294: Verify_before/after_young_collection should execute all verification
Reviewed-by: iwalulya, kbarrett
1 parent 18b80c7 commit 248aa50

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/hotspot/share/gc/g1/g1CollectedHeap.cpp

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2839,6 +2839,8 @@ G1HeapVerifier::G1VerifyType G1CollectedHeap::young_collection_verify_type() con
28392839
}
28402840

28412841
void G1CollectedHeap::verify_before_young_collection(G1HeapVerifier::G1VerifyType type) {
2842+
_verifier->verify_region_sets_optional();
2843+
_verifier->verify_dirty_young_regions();
28422844
if (VerifyRememberedSets) {
28432845
log_info(gc, verify)("[Verifying RemSets before GC]");
28442846
VerifyRegionRemSetClosure v_cl;
@@ -2861,6 +2863,7 @@ void G1CollectedHeap::verify_after_young_collection(G1HeapVerifier::G1VerifyType
28612863
_verifier->verify_after_gc(type);
28622864
_verifier->check_bitmaps("GC End");
28632865
verify_numa_regions("GC End");
2866+
_verifier->verify_region_sets_optional();
28642867
}
28652868

28662869
void G1CollectedHeap::expand_heap_after_young_collection(){
@@ -2959,9 +2962,6 @@ void G1CollectedHeap::do_collection_pause_at_safepoint_helper(double target_paus
29592962
print_heap_regions();
29602963
trace_heap_before_gc(_gc_tracer_stw);
29612964

2962-
_verifier->verify_region_sets_optional();
2963-
_verifier->verify_dirty_young_regions();
2964-
29652965
// We should not be doing concurrent start unless the concurrent mark thread is running
29662966
if (!_cm_thread->should_terminate()) {
29672967
// This call will decide whether this pause is a concurrent start
@@ -3082,9 +3082,6 @@ void G1CollectedHeap::do_collection_pause_at_safepoint_helper(double target_paus
30823082
policy()->print_phases();
30833083
heap_transition.print();
30843084

3085-
_hrm.verify_optional();
3086-
_verifier->verify_region_sets_optional();
3087-
30883085
TASKQUEUE_STATS_ONLY(print_taskqueue_stats());
30893086
TASKQUEUE_STATS_ONLY(reset_taskqueue_stats());
30903087

0 commit comments

Comments
 (0)