< prev index next >

src/share/vm/gc/parallel/psParallelCompact.cpp

Print this page

        

*** 2105,2125 **** } // This is the point where the entire marking should have completed. assert(cm->marking_stacks_empty(), "Marking should have completed"); ! { GCTraceTime(Debug, gc, phases) tm_m("Class Unloading", &_gc_timer); // Follow system dictionary roots and unload classes. bool purged_class = SystemDictionary::do_unloading(is_alive_closure()); // 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()); } { GCTraceTime(Debug, gc, phases) t("Scrub String Table", &_gc_timer); // Delete entries for dead interned strings. --- 2105,2129 ---- } // This is the point where the entire marking should have completed. assert(cm->marking_stacks_empty(), "Marking should have completed"); ! if (ClassUnloading) { GCTraceTime(Debug, gc, phases) tm_m("Class Unloading", &_gc_timer); // Follow system dictionary roots and unload classes. bool purged_class = SystemDictionary::do_unloading(is_alive_closure()); // 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()); + } else { + // Unload nmethods. + GCTraceTime(Debug, gc, phases) tm_m("NMethod Unloading", &_gc_timer); + CodeCache::do_unloading(is_alive_closure(), false); } { GCTraceTime(Debug, gc, phases) t("Scrub String Table", &_gc_timer); // Delete entries for dead interned strings.
< prev index next >