8273940: vmTestbase/vm/mlvm/meth/stress/gc/callSequencesDuringGC/Test.java crashes in full gc during VM exit

Reviewed-by: lkorinth
This commit is contained in:
Thomas Schatzl 2021-09-20 16:17:52 +00:00
parent dad5d27172
commit 4b3a4fff39
3 changed files with 3 additions and 14 deletions

View File

@ -2036,8 +2036,9 @@ void G1ConcurrentMark::concurrent_cycle_abort() {
for (uint i = 0; i < _max_num_tasks; ++i) {
_tasks[i]->clear_region_fields();
}
abort_marking_threads();
_first_overflow_barrier_sync.abort();
_second_overflow_barrier_sync.abort();
_has_aborted = true;
SATBMarkQueueSet& satb_mq_set = G1BarrierSet::satb_mark_queue_set();
satb_mq_set.abandon_partial_marking();
@ -2048,12 +2049,6 @@ void G1ConcurrentMark::concurrent_cycle_abort() {
satb_mq_set.is_active() /* expected_active */);
}
void G1ConcurrentMark::abort_marking_threads() {
_has_aborted = true;
_first_overflow_barrier_sync.abort();
_second_overflow_barrier_sync.abort();
}
static void print_ms_time_info(const char* prefix, const char* name,
NumberSeq& ns) {
log_trace(gc, marking)("%s%5d %12s: total time = %8.2f s (avg = %8.2f ms).",

View File

@ -495,10 +495,6 @@ public:
void concurrent_cycle_abort();
void concurrent_cycle_end();
// Notifies marking threads to abort. This is a best-effort notification. Does not
// guarantee or update any state after the call.
void abort_marking_threads();
void update_accum_task_vtime(int i, double vtime) {
_accum_task_vtime[i] += vtime;
}

View File

@ -159,8 +159,6 @@ void G1ConcurrentMarkThread::run_service() {
}
void G1ConcurrentMarkThread::stop_service() {
_cm->abort_marking_threads();
MutexLocker ml(CGC_lock, Mutex::_no_safepoint_check_flag);
CGC_lock->notify_all();
}