272 // |
272 // |
273 // That is, if we assume the heap is at its desired maximum occupancy at the |
273 // That is, if we assume the heap is at its desired maximum occupancy at the |
274 // end of a collection, we let CMSTriggerRatio of the (purported) free |
274 // end of a collection, we let CMSTriggerRatio of the (purported) free |
275 // space be allocated before initiating a new collection cycle. |
275 // space be allocated before initiating a new collection cycle. |
276 // |
276 // |
277 void ConcurrentMarkSweepGeneration::init_initiating_occupancy(intx io, intx tr) { |
277 void ConcurrentMarkSweepGeneration::init_initiating_occupancy(intx io, uintx tr) { |
278 assert(io <= 100 && tr >= 0 && tr <= 100, "Check the arguments"); |
278 assert(io <= 100 && tr <= 100, "Check the arguments"); |
279 if (io >= 0) { |
279 if (io >= 0) { |
280 _initiating_occupancy = (double)io / 100.0; |
280 _initiating_occupancy = (double)io / 100.0; |
281 } else { |
281 } else { |
282 _initiating_occupancy = ((100 - MinHeapFreeRatio) + |
282 _initiating_occupancy = ((100 - MinHeapFreeRatio) + |
283 (double)(tr * MinHeapFreeRatio) / 100.0) |
283 (double)(tr * MinHeapFreeRatio) / 100.0) |