hotspot/src/share/vm/prims/jvmtiTagMap.cpp
changeset 3908 24b55ad4c228
parent 2105 347008ce7984
child 4571 80b553bddc26
--- a/hotspot/src/share/vm/prims/jvmtiTagMap.cpp	Tue Sep 15 11:09:34 2009 -0700
+++ b/hotspot/src/share/vm/prims/jvmtiTagMap.cpp	Tue Sep 15 21:53:47 2009 -0700
@@ -3126,6 +3126,12 @@
   // exceptions) will be visible.
   blk.set_kind(JVMTI_HEAP_REFERENCE_OTHER);
   Universe::oops_do(&blk);
+
+  // If there are any non-perm roots in the code cache, visit them.
+  blk.set_kind(JVMTI_HEAP_REFERENCE_OTHER);
+  CodeBlobToOopClosure look_in_blobs(&blk, false);
+  CodeCache::scavenge_root_nmethods_do(&look_in_blobs);
+
   return true;
 }