--- old/src/hotspot/share/gc/g1/g1CollectedHeap.hpp 2019-03-13 14:02:58.382956089 +0100 +++ new/src/hotspot/share/gc/g1/g1CollectedHeap.hpp 2019-03-13 14:02:58.169950305 +0100 @@ -143,9 +143,8 @@ // Closures used in implementation. friend class G1ParScanThreadState; friend class G1ParScanThreadStateSet; - friend class G1ParTask; + friend class G1EvacuateRegionsTask; friend class G1PLABAllocator; - friend class G1PrepareCompactClosure; // Other related classes. friend class HeapRegionClaimer; @@ -519,6 +518,8 @@ WorkGang* workers() const { return _workers; } + Tickspan run_task(AbstractGangTask* task, uint num_workers = 0); + G1Allocator* allocator() { return _allocator; } @@ -738,10 +739,11 @@ void calculate_collection_set(G1EvacuationInfo& evacuation_info, double target_pause_time_ms); - // Actually do the work of evacuating the collection set. - void evacuate_collection_set(G1ParScanThreadStateSet* per_thread_states); + // Actually do the work of evacuating the parts of the collection set. + void evacuate_initial_collection_set(G1ParScanThreadStateSet* per_thread_states); void evacuate_optional_collection_set(G1ParScanThreadStateSet* per_thread_states); - void evacuate_optional_regions(G1ParScanThreadStateSet* per_thread_states, G1OptionalCSet* ocset); + // Evacuate the next set of optional regions. + void evacuate_next_optional_regions(G1ParScanThreadStateSet* per_thread_states); void pre_evacuate_collection_set(G1EvacuationInfo& evacuation_info); void post_evacuate_collection_set(G1EvacuationInfo& evacuation_info, G1ParScanThreadStateSet* pss); @@ -1424,7 +1426,7 @@ size_t _term_attempts; void start_term_time() { _term_attempts++; _start_term = os::elapsedTime(); } - void end_term_time() { _term_time += os::elapsedTime() - _start_term; } + void end_term_time() { _term_time += (os::elapsedTime() - _start_term); } protected: G1CollectedHeap* _g1h; G1ParScanThreadState* _par_scan_state;