< prev index next >

src/share/vm/gc/g1/g1CollectorPolicy.cpp

Print this page




 224                  "MaxGCPauseMillis (%u) should be less than "
 225                  "GCPauseIntervalMillis (%u)",
 226                  MaxGCPauseMillis, GCPauseIntervalMillis);
 227     vm_exit_during_initialization(buffer);
 228   }
 229 
 230   double max_gc_time = (double) MaxGCPauseMillis / 1000.0;
 231   double time_slice  = (double) GCPauseIntervalMillis / 1000.0;
 232   _mmu_tracker = new G1MMUTrackerQueue(time_slice, max_gc_time);
 233 
 234   // start conservatively (around 50ms is about right)
 235   _concurrent_mark_remark_times_ms->add(0.05);
 236   _concurrent_mark_cleanup_times_ms->add(0.20);
 237   _tenuring_threshold = MaxTenuringThreshold;
 238 
 239   assert(GCTimeRatio > 0,
 240          "we should have set it to a default value set_g1_gc_flags() "
 241          "if a user set it to 0");
 242   _gc_overhead_perc = 100.0 * (1.0 / (1.0 + GCTimeRatio));
 243 
 244   uintx reserve_perc = G1ReservePercent;
 245   // Put an artificial ceiling on this so that it's not set to a silly value.
 246   if (reserve_perc > 50) {
 247     reserve_perc = 50;
 248     warning("G1ReservePercent is set to a value that is too large, "
 249             "it's been updated to " UINTX_FORMAT, reserve_perc);
 250   }
 251   _reserve_factor = (double) reserve_perc / 100.0;
 252   // This will be set when the heap is expanded
 253   // for the first time during initialization.
 254   _reserve_regions = 0;
 255 
 256   _ihop_control = create_ihop_control();
 257 }
 258 
 259 G1CollectorPolicy::~G1CollectorPolicy() {
 260   delete _ihop_control;
 261 }
 262 
 263 double G1CollectorPolicy::get_new_prediction(TruncatedSeq const* seq) const {
 264   return _predictor.get_new_prediction(seq);
 265 }
 266 
 267 size_t G1CollectorPolicy::get_new_size_prediction(TruncatedSeq const* seq) const {
 268   return (size_t)get_new_prediction(seq);
 269 }
 270 
 271 void G1CollectorPolicy::initialize_alignments() {




 224                  "MaxGCPauseMillis (%u) should be less than "
 225                  "GCPauseIntervalMillis (%u)",
 226                  MaxGCPauseMillis, GCPauseIntervalMillis);
 227     vm_exit_during_initialization(buffer);
 228   }
 229 
 230   double max_gc_time = (double) MaxGCPauseMillis / 1000.0;
 231   double time_slice  = (double) GCPauseIntervalMillis / 1000.0;
 232   _mmu_tracker = new G1MMUTrackerQueue(time_slice, max_gc_time);
 233 
 234   // start conservatively (around 50ms is about right)
 235   _concurrent_mark_remark_times_ms->add(0.05);
 236   _concurrent_mark_cleanup_times_ms->add(0.20);
 237   _tenuring_threshold = MaxTenuringThreshold;
 238 
 239   assert(GCTimeRatio > 0,
 240          "we should have set it to a default value set_g1_gc_flags() "
 241          "if a user set it to 0");
 242   _gc_overhead_perc = 100.0 * (1.0 / (1.0 + GCTimeRatio));
 243 
 244   guarantee(G1ReservePercent <= 50, "Range checking should not allow values over 50.");
 245   _reserve_factor = (double) G1ReservePercent / 100.0;






 246   // This will be set when the heap is expanded
 247   // for the first time during initialization.
 248   _reserve_regions = 0;
 249 
 250   _ihop_control = create_ihop_control();
 251 }
 252 
 253 G1CollectorPolicy::~G1CollectorPolicy() {
 254   delete _ihop_control;
 255 }
 256 
 257 double G1CollectorPolicy::get_new_prediction(TruncatedSeq const* seq) const {
 258   return _predictor.get_new_prediction(seq);
 259 }
 260 
 261 size_t G1CollectorPolicy::get_new_size_prediction(TruncatedSeq const* seq) const {
 262   return (size_t)get_new_prediction(seq);
 263 }
 264 
 265 void G1CollectorPolicy::initialize_alignments() {


< prev index next >