8244714: G1 young gen sizer allows zero young gen with huge -XX:NewRatio
Reviewed-by: sjohanss
This commit is contained in:
parent
7345502884
commit
0dab181993
@ -102,7 +102,7 @@ void G1YoungGenSizer::recalculate_min_max_young_length(uint number_of_heap_regio
|
||||
// Do nothing. Values set on the command line, don't update them at runtime.
|
||||
break;
|
||||
case SizerNewRatio:
|
||||
*min_young_length = number_of_heap_regions / (NewRatio + 1);
|
||||
*min_young_length = MAX2((uint)(number_of_heap_regions / (NewRatio + 1)), 1u);
|
||||
*max_young_length = *min_young_length;
|
||||
break;
|
||||
default:
|
||||
|
Loading…
x
Reference in New Issue
Block a user