< prev index next >

src/hotspot/share/gc/shenandoah/shenandoahControlThread.cpp

Print this page
rev 59271 : 8240870: Shenandoah: merge evac and update phases
Reviewed-by: XXX

*** 311,345 **** // // There are also a shortcut through the normal cycle: immediate garbage shortcut, when // heuristics says there are no regions to compact, and all the collection comes from immediately // reclaimable regions. // ! // ................................................................................................ // ! // (immediate garbage shortcut) Concurrent GC ! // /-------------------------------------------\ ! // | | ! // | | ! // | | ! // | v ! // [START] ----> Conc Mark ----o----> Conc Evac --o--> Conc Update-Refs ---o----> [END] ! // | | | ^ ! // | (af) | (af) | (af) | ! // ..................|....................|.................|..............|....................... ! // | | | | ! // | | | | Degenerated GC ! // v v v | ! // STW Mark ----------> STW Evac ----> STW Update-Refs ----->o ! // | | | ^ ! // | (af) | (af) | (af) | ! // ..................|....................|.................|..............|....................... ! // | | | | ! // | v | | Full GC ! // \------------------->o<----------------/ | ! // | | ! // v | ! // Full GC --------------------------/ // ShenandoahHeap* heap = ShenandoahHeap::heap(); if (check_cancellation_or_degen(ShenandoahHeap::_degenerated_outside_cycle)) return; --- 311,345 ---- // // There are also a shortcut through the normal cycle: immediate garbage shortcut, when // heuristics says there are no regions to compact, and all the collection comes from immediately // reclaimable regions. // ! // ........................................................................................ // ! // (immediate garbage shortcut) Concurrent GC ! // /-----------------------------------\ ! // | | ! // | | ! // | | ! // | v ! // [START] ----> Conc Mark ----o---> Conc Evac-Update ---------> [END] ! // | | ^ ! // | (af) | (af) | ! // ..................|.....................|.......................|....................... ! // | | | ! // | | | Degenerated GC ! // v v | ! // STW Mark ---------> STW Evac-Update ------------->o ! // | | ^ ! // | (af) | (af) | ! // ..................|.....................|.......................|....................... ! // | | | ! // | v | Full GC ! // \-------------------->o | ! // | | ! // v | ! // Full GC ------------------/ // ShenandoahHeap* heap = ShenandoahHeap::heap(); if (check_cancellation_or_degen(ShenandoahHeap::_degenerated_outside_cycle)) return;
*** 392,411 **** // Continue the cycle with evacuation and optional update-refs. // This may be skipped if there is nothing to evacuate. // If so, evac_in_progress would be unset by collection set preparation code. if (heap->is_evacuation_in_progress()) { ! // Concurrently evacuate ! heap->entry_evac(); ! if (check_cancellation_or_degen(ShenandoahHeap::_degenerated_evac)) return; ! ! // Perform update-refs phase. ! heap->vmop_entry_init_updaterefs(); ! heap->entry_updaterefs(); ! if (check_cancellation_or_degen(ShenandoahHeap::_degenerated_updaterefs)) return; ! heap->vmop_entry_final_updaterefs(); // Update references freed up collection set, kick the cleanup to reclaim the space. heap->entry_cleanup_complete(); } --- 392,408 ---- // Continue the cycle with evacuation and optional update-refs. // This may be skipped if there is nothing to evacuate. // If so, evac_in_progress would be unset by collection set preparation code. if (heap->is_evacuation_in_progress()) { ! heap->vmop_entry_init_evac_update(); ! // Concurrently evacuate and update the refs ! heap->entry_evac_update(); ! if (check_cancellation_or_degen(ShenandoahHeap::_degenerated_evac_update)) return; ! ! heap->vmop_entry_final_evac_update(); // Update references freed up collection set, kick the cleanup to reclaim the space. heap->entry_cleanup_complete(); }
< prev index next >