hotspot/src/share/vm/runtime/safepoint.cpp
changeset 13087 673ea6efaf18
parent 12108 b2ee55606008
child 13195 be27e1b6a4b9
--- a/hotspot/src/share/vm/runtime/safepoint.cpp	Mon Jun 11 13:10:14 2012 -0400
+++ b/hotspot/src/share/vm/runtime/safepoint.cpp	Wed Jun 13 19:52:59 2012 -0400
@@ -23,6 +23,7 @@
  */
 
 #include "precompiled.hpp"
+#include "classfile/symbolTable.hpp"
 #include "classfile/systemDictionary.hpp"
 #include "code/codeCache.hpp"
 #include "code/icBuffer.hpp"
@@ -526,8 +527,20 @@
     CompilationPolicy::policy()->do_safepoint_work();
   }
 
-  TraceTime t4("sweeping nmethods", TraceSafepointCleanupTime);
-  NMethodSweeper::scan_stacks();
+  {
+    TraceTime t4("sweeping nmethods", TraceSafepointCleanupTime);
+    NMethodSweeper::scan_stacks();
+  }
+
+  if (SymbolTable::needs_rehashing()) {
+    TraceTime t5("rehashing symbol table", TraceSafepointCleanupTime);
+    SymbolTable::rehash_table();
+  }
+
+  if (StringTable::needs_rehashing()) {
+    TraceTime t6("rehashing string table", TraceSafepointCleanupTime);
+    StringTable::rehash_table();
+  }
 
   // rotate log files?
   if (UseGCLogFileRotation) {