changeset 7005:45029b3ac59f

fixed bug in the resetting of static call stubs that caused infinite, safepoint free loops in non-product builds of the VM
author Doug Simon <doug.simon@oracle.com>
date Thu, 22 Nov 2012 23:36:04 +0100
parents 1d419abb0081
children 7e12f1d11a5d b618f7c63d17 7d815d842ee0
files src/share/vm/code/nmethod.cpp
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/code/nmethod.cpp	Thu Nov 22 23:34:49 2012 +0100
+++ b/src/share/vm/code/nmethod.cpp	Thu Nov 22 23:36:04 2012 +0100
@@ -1792,8 +1792,8 @@
 // really alive.
 void nmethod::verify_metadata_loaders(address low_boundary, BoolObjectClosure* is_alive) {
 #ifdef ASSERT
-    RelocIterator iter(this, low_boundary);
-    while (iter.next()) {
+  RelocIterator iter(this, low_boundary);
+  while (iter.next()) {
     // static_stub_Relocations may have dangling references to
     // Method*s so trim them out here.  Otherwise it looks like
     // compiled code is maintaining a link to dead metadata.
@@ -1802,11 +1802,13 @@
       CompiledIC* cic = CompiledIC_at(iter.reloc());
       if (!cic->is_call_to_interpreted()) {
         static_call_addr = iter.addr();
+        cic->set_to_clean();
       }
     } else if (iter.type() == relocInfo::static_call_type) {
       CompiledStaticCall* csc = compiledStaticCall_at(iter.reloc());
       if (!csc->is_call_to_interpreted()) {
         static_call_addr = iter.addr();
+        csc->set_to_clean();
       }
     }
     if (static_call_addr != NULL) {