hotspot/src/share/vm/gc/parallel/psMarkSweep.cpp
changeset 37140 b62549ead2cf
parent 37106 0856b64af754
child 37146 209e0fe518bb
--- a/hotspot/src/share/vm/gc/parallel/psMarkSweep.cpp	Thu Mar 17 21:00:51 2016 +0100
+++ b/hotspot/src/share/vm/gc/parallel/psMarkSweep.cpp	Thu Mar 17 21:01:59 2016 +0100
@@ -533,20 +533,31 @@
   // This is the point where the entire marking should have completed.
   assert(_marking_stack.is_empty(), "Marking should have completed");
 
-  // Unload classes and purge the SystemDictionary.
-  bool purged_class = SystemDictionary::do_unloading(is_alive_closure());
+  {
+    GCTraceTime(Debug, gc) t("Class Unloading", _gc_timer);
+
+    // Unload classes and purge the SystemDictionary.
+    bool purged_class = SystemDictionary::do_unloading(is_alive_closure());
 
-  // Unload nmethods.
-  CodeCache::do_unloading(is_alive_closure(), purged_class);
+    // Unload nmethods.
+    CodeCache::do_unloading(is_alive_closure(), purged_class);
+
+    // Prune dead klasses from subklass/sibling/implementor lists.
+    Klass::clean_weak_klass_links(is_alive_closure());
+  }
 
-  // Prune dead klasses from subklass/sibling/implementor lists.
-  Klass::clean_weak_klass_links(is_alive_closure());
+  {
+    GCTraceTime(Debug, gc) t("Scrub String Table", _gc_timer);
+    // Delete entries for dead interned strings.
+    StringTable::unlink(is_alive_closure());
+  }
 
-  // Delete entries for dead interned strings.
-  StringTable::unlink(is_alive_closure());
+  {
+    GCTraceTime(Debug, gc) t("Scrub Symbol Table", _gc_timer);
+    // Clean up unreferenced symbols in symbol table.
+    SymbolTable::unlink();
+  }
 
-  // Clean up unreferenced symbols in symbol table.
-  SymbolTable::unlink();
   _gc_tracer->report_object_count_after_gc(is_alive_closure());
 }