8328275: CodeCache::print_internals should not be called in PRODUCT code

Reviewed-by: ihse, jwaters, dholmes
This commit is contained in:
Daniel Jeliński 2024-03-19 06:40:58 +00:00
parent 4ef591f71f
commit c0fc9563a7

View File

@ -316,10 +316,12 @@ void print_statistics() {
CompileBroker::print_heapinfo(nullptr, "all", 4096); // details
}
#ifndef PRODUCT
if (PrintCodeCache2) {
MutexLocker mu(CodeCache_lock, Mutex::_no_safepoint_check_flag);
CodeCache::print_internals();
}
#endif
if (VerifyOops && Verbose) {
tty->print_cr("+VerifyOops count: %d", StubRoutines::verify_oop_count());