< prev index next >

src/hotspot/share/gc/parallel/psMarkSweep.cpp

Print this page

        

*** 191,201 **** // Let the size policy know we're starting size_policy->major_collection_begin(); BiasedLocking::preserve_marks(); ! const PreGenGCValues pre_gc_values = heap->get_pre_gc_values(); allocate_stacks(); #if COMPILER2_OR_JVMCI DerivedPointerTable::clear(); --- 191,205 ---- // Let the size policy know we're starting size_policy->major_collection_begin(); BiasedLocking::preserve_marks(); ! // Capture metadata size before collection for sizing. ! size_t metadata_prev_used = MetaspaceUtils::used_bytes(); ! ! size_t old_gen_prev_used = old_gen->used_in_bytes(); ! size_t young_gen_prev_used = young_gen->used_in_bytes(); allocate_stacks(); #if COMPILER2_OR_JVMCI DerivedPointerTable::clear();
*** 253,262 **** --- 257,267 ---- ClassLoaderDataGraph::purge(); MetaspaceUtils::verify_metrics(); BiasedLocking::restore_marks(); heap->prune_scavengable_nmethods(); + JvmtiExport::gc_epilogue(); #if COMPILER2_OR_JVMCI DerivedPointerTable::update_pointers(); #endif
*** 346,356 **** if (log_is_enabled(Debug, gc, heap, exit)) { accumulated_time()->stop(); } ! heap->print_heap_change(pre_gc_values); // Track memory usage and detect low memory MemoryService::track_memory_usage(); heap->update_counters(); --- 351,363 ---- if (log_is_enabled(Debug, gc, heap, exit)) { accumulated_time()->stop(); } ! young_gen->print_used_change(young_gen_prev_used); ! old_gen->print_used_change(old_gen_prev_used); ! MetaspaceUtils::print_metaspace_change(metadata_prev_used); // Track memory usage and detect low memory MemoryService::track_memory_usage(); heap->update_counters();
*** 520,529 **** --- 527,537 ---- SystemDictionary::oops_do(mark_and_push_closure()); ClassLoaderDataGraph::always_strong_cld_do(follow_cld_closure()); // Do not treat nmethods as strong roots for mark/sweep, since we can unload them. //ScavengableNMethods::scavengable_nmethods_do(CodeBlobToOopClosure(mark_and_push_closure())); AOT_ONLY(AOTLoader::oops_do(mark_and_push_closure());) + JVMCI_ONLY(JVMCI::oops_do(mark_and_push_closure());) } // Flush marking stack. follow_stack();
*** 615,624 **** --- 623,634 ---- CodeBlobToOopClosure adjust_from_blobs(adjust_pointer_closure(), CodeBlobToOopClosure::FixRelocations); CodeCache::blobs_do(&adjust_from_blobs); AOT_ONLY(AOTLoader::oops_do(adjust_pointer_closure());) + JVMCI_ONLY(JVMCI::oops_do(adjust_pointer_closure());) + ref_processor()->weak_oops_do(adjust_pointer_closure()); PSScavenge::reference_processor()->weak_oops_do(adjust_pointer_closure()); adjust_marks();
< prev index next >