mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-21 03:24:38 +02:00
8001424: G1: Rename certain G1-specific flags
Rename G1DefaultMinNewGenPercent, G1DefaultMaxNewGenPercent, and G1OldCSetRegionLiveThresholdPercent to G1NewSizePercent, G1MaxNewSizePercent, and G1MixedGCLiveThresholdPercent respectively. The previous names are no longer accepted. Reviewed-by: brutisso, ysr
This commit is contained in:
parent
7cb614b0e5
commit
2df5f7cc5a
4 changed files with 24 additions and 23 deletions
|
@ -85,7 +85,7 @@ CollectionSetChooser::CollectionSetChooser() :
|
||||||
_curr_index(0), _length(0), _first_par_unreserved_idx(0),
|
_curr_index(0), _length(0), _first_par_unreserved_idx(0),
|
||||||
_region_live_threshold_bytes(0), _remaining_reclaimable_bytes(0) {
|
_region_live_threshold_bytes(0), _remaining_reclaimable_bytes(0) {
|
||||||
_region_live_threshold_bytes =
|
_region_live_threshold_bytes =
|
||||||
HeapRegion::GrainBytes * (size_t) G1OldCSetRegionLiveThresholdPercent / 100;
|
HeapRegion::GrainBytes * (size_t) G1MixedGCLiveThresholdPercent / 100;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef PRODUCT
|
#ifndef PRODUCT
|
||||||
|
|
|
@ -309,9 +309,9 @@ void G1CollectorPolicy::initialize_flags() {
|
||||||
}
|
}
|
||||||
|
|
||||||
G1YoungGenSizer::G1YoungGenSizer() : _sizer_kind(SizerDefaults), _adaptive_size(true) {
|
G1YoungGenSizer::G1YoungGenSizer() : _sizer_kind(SizerDefaults), _adaptive_size(true) {
|
||||||
assert(G1DefaultMinNewGenPercent <= G1DefaultMaxNewGenPercent, "Min larger than max");
|
assert(G1NewSizePercent <= G1MaxNewSizePercent, "Min larger than max");
|
||||||
assert(G1DefaultMinNewGenPercent > 0 && G1DefaultMinNewGenPercent < 100, "Min out of bounds");
|
assert(G1NewSizePercent > 0 && G1NewSizePercent < 100, "Min out of bounds");
|
||||||
assert(G1DefaultMaxNewGenPercent > 0 && G1DefaultMaxNewGenPercent < 100, "Max out of bounds");
|
assert(G1MaxNewSizePercent > 0 && G1MaxNewSizePercent < 100, "Max out of bounds");
|
||||||
|
|
||||||
if (FLAG_IS_CMDLINE(NewRatio)) {
|
if (FLAG_IS_CMDLINE(NewRatio)) {
|
||||||
if (FLAG_IS_CMDLINE(NewSize) || FLAG_IS_CMDLINE(MaxNewSize)) {
|
if (FLAG_IS_CMDLINE(NewSize) || FLAG_IS_CMDLINE(MaxNewSize)) {
|
||||||
|
@ -344,12 +344,12 @@ G1YoungGenSizer::G1YoungGenSizer() : _sizer_kind(SizerDefaults), _adaptive_size(
|
||||||
}
|
}
|
||||||
|
|
||||||
uint G1YoungGenSizer::calculate_default_min_length(uint new_number_of_heap_regions) {
|
uint G1YoungGenSizer::calculate_default_min_length(uint new_number_of_heap_regions) {
|
||||||
uint default_value = (new_number_of_heap_regions * G1DefaultMinNewGenPercent) / 100;
|
uint default_value = (new_number_of_heap_regions * G1NewSizePercent) / 100;
|
||||||
return MAX2(1U, default_value);
|
return MAX2(1U, default_value);
|
||||||
}
|
}
|
||||||
|
|
||||||
uint G1YoungGenSizer::calculate_default_max_length(uint new_number_of_heap_regions) {
|
uint G1YoungGenSizer::calculate_default_max_length(uint new_number_of_heap_regions) {
|
||||||
uint default_value = (new_number_of_heap_regions * G1DefaultMaxNewGenPercent) / 100;
|
uint default_value = (new_number_of_heap_regions * G1MaxNewSizePercent) / 100;
|
||||||
return MAX2(1U, default_value);
|
return MAX2(1U, default_value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -94,18 +94,18 @@ class TraceGen1TimeData : public CHeapObj<mtGC> {
|
||||||
// will occur.
|
// will occur.
|
||||||
//
|
//
|
||||||
// If nothing related to the the young gen size is set on the command
|
// If nothing related to the the young gen size is set on the command
|
||||||
// line we should allow the young gen to be between
|
// line we should allow the young gen to be between G1NewSizePercent
|
||||||
// G1DefaultMinNewGenPercent and G1DefaultMaxNewGenPercent of the
|
// and G1MaxNewSizePercent of the heap size. This means that every time
|
||||||
// heap size. This means that every time the heap size changes the
|
// the heap size changes, the limits for the young gen size will be
|
||||||
// limits for the young gen size will be updated.
|
// recalculated.
|
||||||
//
|
//
|
||||||
// If only -XX:NewSize is set we should use the specified value as the
|
// If only -XX:NewSize is set we should use the specified value as the
|
||||||
// minimum size for young gen. Still using G1DefaultMaxNewGenPercent
|
// minimum size for young gen. Still using G1MaxNewSizePercent of the
|
||||||
// of the heap as maximum.
|
// heap as maximum.
|
||||||
//
|
//
|
||||||
// If only -XX:MaxNewSize is set we should use the specified value as the
|
// If only -XX:MaxNewSize is set we should use the specified value as the
|
||||||
// maximum size for young gen. Still using G1DefaultMinNewGenPercent
|
// maximum size for young gen. Still using G1NewSizePercent of the heap
|
||||||
// of the heap as minimum.
|
// as minimum.
|
||||||
//
|
//
|
||||||
// If -XX:NewSize and -XX:MaxNewSize are both specified we use these values.
|
// If -XX:NewSize and -XX:MaxNewSize are both specified we use these values.
|
||||||
// No updates when the heap size changes. There is a special case when
|
// No updates when the heap size changes. There is a special case when
|
||||||
|
|
|
@ -287,17 +287,18 @@
|
||||||
"The number of times we'll force an overflow during " \
|
"The number of times we'll force an overflow during " \
|
||||||
"concurrent marking") \
|
"concurrent marking") \
|
||||||
\
|
\
|
||||||
experimental(uintx, G1DefaultMinNewGenPercent, 20, \
|
experimental(uintx, G1NewSizePercent, 20, \
|
||||||
"Percentage (0-100) of the heap size to use as minimum " \
|
"Percentage (0-100) of the heap size to use as default " \
|
||||||
"young gen size.") \
|
"minimum young gen size.") \
|
||||||
\
|
\
|
||||||
experimental(uintx, G1DefaultMaxNewGenPercent, 80, \
|
experimental(uintx, G1MaxNewSizePercent, 80, \
|
||||||
"Percentage (0-100) of the heap size to use as maximum " \
|
"Percentage (0-100) of the heap size to use as default " \
|
||||||
"young gen size.") \
|
" maximum young gen size.") \
|
||||||
\
|
\
|
||||||
experimental(uintx, G1OldCSetRegionLiveThresholdPercent, 90, \
|
experimental(uintx, G1MixedGCLiveThresholdPercent, 90, \
|
||||||
"Threshold for regions to be added to the collection set. " \
|
"Threshold for regions to be considered for inclusion in the " \
|
||||||
"Regions with more live bytes than this will not be collected.") \
|
"collection set of mixed GCs. " \
|
||||||
|
"Regions with live bytes exceeding this will not be collected.") \
|
||||||
\
|
\
|
||||||
product(uintx, G1HeapWastePercent, 5, \
|
product(uintx, G1HeapWastePercent, 5, \
|
||||||
"Amount of space, expressed as a percentage of the heap size, " \
|
"Amount of space, expressed as a percentage of the heap size, " \
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue