comparison src/share/vm/gc_implementation/g1/g1CollectorPolicy.hpp @ 13060:8f07aa079343

8016309: assert(eden_size > 0 && survivor_size > 0) failed: just checking 7057939: jmap shows MaxNewSize=4GB when Java is using parallel collector Summary: Major cleanup of the collectorpolicy classes Reviewed-by: tschatzl, jcoomes
author jwilhelm
date Fri, 01 Nov 2013 17:09:38 +0100
parents 46d7652b223c
children 63a4eb8bcd23 cfd4aac53239
comparison
equal deleted inserted replaced
13059:46d7652b223c 13060:8f07aa079343
134 uint _max_desired_young_length; 134 uint _max_desired_young_length;
135 bool _adaptive_size; 135 bool _adaptive_size;
136 uint calculate_default_min_length(uint new_number_of_heap_regions); 136 uint calculate_default_min_length(uint new_number_of_heap_regions);
137 uint calculate_default_max_length(uint new_number_of_heap_regions); 137 uint calculate_default_max_length(uint new_number_of_heap_regions);
138 138
139 // Update the given values for minimum and maximum young gen length in regions
140 // given the number of heap regions depending on the kind of sizing algorithm.
141 void recalculate_min_max_young_length(uint number_of_heap_regions, uint* min_young_length, uint* max_young_length);
142
139 public: 143 public:
140 G1YoungGenSizer(); 144 G1YoungGenSizer();
145 // Calculate the maximum length of the young gen given the number of regions
146 // depending on the sizing algorithm.
147 uint max_young_length(uint number_of_heap_regions);
148
141 void heap_size_changed(uint new_number_of_heap_regions); 149 void heap_size_changed(uint new_number_of_heap_regions);
142 uint min_desired_young_length() { 150 uint min_desired_young_length() {
143 return _min_desired_young_length; 151 return _min_desired_young_length;
144 } 152 }
145 uint max_desired_young_length() { 153 uint max_desired_young_length() {
163 NumPrevPausesForHeuristics = 10 171 NumPrevPausesForHeuristics = 10
164 }; 172 };
165 173
166 G1MMUTracker* _mmu_tracker; 174 G1MMUTracker* _mmu_tracker;
167 175
176 void initialize_alignments();
168 void initialize_flags(); 177 void initialize_flags();
169
170 void initialize_all() {
171 initialize_flags();
172 initialize_size_info();
173 }
174 178
175 CollectionSetChooser* _collectionSetChooser; 179 CollectionSetChooser* _collectionSetChooser;
176 180
177 double _full_collection_start_sec; 181 double _full_collection_start_sec;
178 uint _cur_collection_pause_used_regions_at_start; 182 uint _cur_collection_pause_used_regions_at_start;
929 void update_max_gc_locker_expansion(); 933 void update_max_gc_locker_expansion();
930 934
931 // Calculates survivor space parameters. 935 // Calculates survivor space parameters.
932 void update_survivors_policy(); 936 void update_survivors_policy();
933 937
938 virtual void post_heap_initialize();
934 }; 939 };
935 940
936 // This should move to some place more general... 941 // This should move to some place more general...
937 942
938 // If we have "n" measurements, and we've kept track of their "sum" and the 943 // If we have "n" measurements, and we've kept track of their "sum" and the