mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-25 13:54:38 +02:00
8058461: serviceability/dcmd/CodelistTest.java and serviceability/dcmd/CompilerQueueTest.java SIGSEGV
Print only alive nmethods and add lock to print compile queue Reviewed-by: kvn, anoll
This commit is contained in:
parent
c82c59cd8f
commit
2dcb0e33bb
2 changed files with 10 additions and 6 deletions
|
@ -783,18 +783,22 @@ CompileQueue* CompileBroker::compile_queue(int comp_level) {
|
|||
|
||||
|
||||
void CompileBroker::print_compile_queues(outputStream* st) {
|
||||
_c1_compile_queue->print(st);
|
||||
_c2_compile_queue->print(st);
|
||||
MutexLocker locker(MethodCompileQueue_lock);
|
||||
if (_c1_compile_queue != NULL) {
|
||||
_c1_compile_queue->print(st);
|
||||
}
|
||||
if (_c2_compile_queue != NULL) {
|
||||
_c2_compile_queue->print(st);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void CompileQueue::print(outputStream* st) {
|
||||
assert_locked_or_safepoint(lock());
|
||||
assert(lock()->owned_by_self(), "must own lock");
|
||||
st->print_cr("Contents of %s", name());
|
||||
st->print_cr("----------------------------");
|
||||
CompileTask* task = _first;
|
||||
if (task == NULL) {
|
||||
st->print_cr("Empty");;
|
||||
st->print_cr("Empty");
|
||||
} else {
|
||||
while (task != NULL) {
|
||||
task->print_compilation(st, NULL, true, true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue