Mercurial > hg > graal-compiler
diff src/share/vm/c1/c1_Runtime1.cpp @ 6423:13a08f5bb120
improved tracing in graal_monitorenter and graal_monitorexit
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Thu, 20 Sep 2012 17:10:58 +0200 |
parents | 6b74f44c5059 |
children | 7d6f44854ee3 |
line wrap: on
line diff
--- a/src/share/vm/c1/c1_Runtime1.cpp Thu Sep 20 17:09:53 2012 +0200 +++ b/src/share/vm/c1/c1_Runtime1.cpp Thu Sep 20 17:10:58 2012 +0200 @@ -687,9 +687,11 @@ NOT_PRODUCT(_monitorenter_slowcase_cnt++;) #ifdef ASSERT if (TraceGraal >= 3) { + char type[1024]; + obj->klass()->klass_part()->name()->as_C_string(type, 1024); markOop mark = obj->mark(); - markOop dmw = mark->has_displaced_mark_helper() ? mark->displaced_mark_helper() : (markOop) (int*) 0xFFFFFFFF; - tty->print_cr("entered locking slow case with obj=" INTPTR_FORMAT ", mark=" INTPTR_FORMAT ", dmw=" INTPTR_FORMAT " and lock= " INTPTR_FORMAT, obj, mark, dmw , lock); + tty->print_cr("entered locking slow case with obj=" INTPTR_FORMAT ", type=%s, mark=" INTPTR_FORMAT ", lock=" INTPTR_FORMAT, obj, type, mark, lock); + tty->flush(); } if (PrintBiasedLockingStatistics) { Atomic::inc(BiasedLocking::slow_path_entry_count_addr()); @@ -744,8 +746,11 @@ ObjectSynchronizer::fast_exit(obj, lock, THREAD); } #ifdef ASSERT - if (TraceGraal >= 3) { - tty->print_cr("exited locking slow case with obj=" INTPTR_FORMAT ", mark=" INTPTR_FORMAT " and lock= " INTPTR_FORMAT, obj, obj->mark(), lock); + if (TraceGraal >= 3 || true) { + char type[1024]; + obj->klass()->klass_part()->name()->as_C_string(type, 1024); + tty->print_cr("exited locking slow case with obj=" INTPTR_FORMAT ", type=%s, mark=" INTPTR_FORMAT ", lock=" INTPTR_FORMAT, obj, type, obj->mark(), lock); + tty->flush(); } #endif JRT_END