--- old/src/hotspot/share/gc/g1/g1HeapSizingPolicy.hpp 2020-02-12 17:18:33.244505545 +0800 +++ new/src/hotspot/share/gc/g1/g1HeapSizingPolicy.hpp 2020-02-12 17:18:33.246505617 +0800 @@ -45,6 +45,9 @@ double _ratio_over_threshold_sum; uint _pauses_since_start; + // Mininum heap capacity after last concurrent mark + size_t _minimum_desired_bytes_after_last_cm; + protected: G1HeapSizingPolicy(const G1CollectedHeap* g1h, const G1Analytics* analytics); @@ -52,7 +55,9 @@ // If an expansion would be appropriate, because recent GC overhead had // exceeded the desired limit, return an amount to expand by. - virtual size_t expansion_amount(); + virtual size_t expansion_amount_after_young_collection(); + virtual size_t expansion_amount_after_concurrent_mark(); + virtual size_t shrink_amount_after_mixed_collections(); // Clear ratio tracking data used by expansion_amount(). void clear_ratio_check_data();