8329109: Threads::print_on() tries to print CPU time for terminated GC threads

Backport-of: c1cfb43d8d
This commit is contained in:
Liang Mao
2024-05-23 08:47:30 +00:00
committed by Vitaly Provodin
parent 26a5760faf
commit 8b00cadfd6

View File

@@ -1323,10 +1323,7 @@ void Threads::print_on(outputStream* st, bool print_stacks,
}
PrintOnClosure cl(st);
cl.do_thread(VMThread::vm_thread());
Universe::heap()->gc_threads_do(&cl);
cl.do_thread(WatcherThread::watcher_thread());
cl.do_thread(AsyncLogWriter::instance());
non_java_threads_do(&cl);
st->flush();
}