357 size_t max_old_gen_size,
358 bool is_full_gc);
359
360 // Calculates new survivor space size; returns a new tenuring threshold
361 // value. Stores new survivor size in _survivor_size.
362 uint compute_survivor_space_size_and_threshold(bool is_survivor_overflow,
363 uint tenuring_threshold,
364 size_t survivor_limit);
365
366 // Return the maximum size of a survivor space if the young generation were of
367 // size gen_size.
368 size_t max_survivor_size(size_t gen_size) {
369 // Never allow the target survivor size to grow more than MinSurvivorRatio
370 // of the young generation size. We cannot grow into a two semi-space
371 // system, with Eden zero sized. Even if the survivor space grows, from()
372 // might grow by moving the bottom boundary "down" -- so from space will
373 // remain almost full anyway (top() will be near end(), but there will be a
374 // large filler object at the bottom).
375 const size_t sz = gen_size / MinSurvivorRatio;
376 const size_t alignment = _space_alignment;
377 return sz > alignment ? align_size_down(sz, alignment) : alignment;
378 }
379
380 size_t live_at_last_full_gc() {
381 return _live_at_last_full_gc;
382 }
383
384 size_t bytes_absorbed_from_eden() const { return _bytes_absorbed_from_eden; }
385 void reset_bytes_absorbed_from_eden() { _bytes_absorbed_from_eden = 0; }
386
387 void set_bytes_absorbed_from_eden(size_t val) {
388 _bytes_absorbed_from_eden = val;
389 }
390
391 // Update averages that are always used (even
392 // if adaptive sizing is turned off).
393 void update_averages(bool is_survivor_overflow,
394 size_t survived,
395 size_t promoted);
396
397 // Printing support
|
357 size_t max_old_gen_size,
358 bool is_full_gc);
359
360 // Calculates new survivor space size; returns a new tenuring threshold
361 // value. Stores new survivor size in _survivor_size.
362 uint compute_survivor_space_size_and_threshold(bool is_survivor_overflow,
363 uint tenuring_threshold,
364 size_t survivor_limit);
365
366 // Return the maximum size of a survivor space if the young generation were of
367 // size gen_size.
368 size_t max_survivor_size(size_t gen_size) {
369 // Never allow the target survivor size to grow more than MinSurvivorRatio
370 // of the young generation size. We cannot grow into a two semi-space
371 // system, with Eden zero sized. Even if the survivor space grows, from()
372 // might grow by moving the bottom boundary "down" -- so from space will
373 // remain almost full anyway (top() will be near end(), but there will be a
374 // large filler object at the bottom).
375 const size_t sz = gen_size / MinSurvivorRatio;
376 const size_t alignment = _space_alignment;
377 return sz > alignment ? align_down(sz, alignment) : alignment;
378 }
379
380 size_t live_at_last_full_gc() {
381 return _live_at_last_full_gc;
382 }
383
384 size_t bytes_absorbed_from_eden() const { return _bytes_absorbed_from_eden; }
385 void reset_bytes_absorbed_from_eden() { _bytes_absorbed_from_eden = 0; }
386
387 void set_bytes_absorbed_from_eden(size_t val) {
388 _bytes_absorbed_from_eden = val;
389 }
390
391 // Update averages that are always used (even
392 // if adaptive sizing is turned off).
393 void update_averages(bool is_survivor_overflow,
394 size_t survived,
395 size_t promoted);
396
397 // Printing support
|