Integrated: 8371672: G1: G1YoungGenSizer handling of NewRatio, NewSize and MaxNewSize
Axel Boldt-Christmas
aboldtch at openjdk.org
Mon Nov 17 07:36:17 UTC 2025
On Wed, 12 Nov 2025 07:40:01 GMT, Axel Boldt-Christmas <aboldtch at openjdk.org> wrote:
> G1YoungGenSizer ignores these values if they are not from the command line. Resulting in a different _sizer_kind than expected.
> The NewSize and MaxNewSize are also not bounded by the Initial and Max heap size respectively ([JDK-8370494](https://bugs.openjdk.org/browse/JDK-8370494)).
>
> I suggest we rewrite this logic using `!FLAG_IS_DEFAULT` to always get the correct behaviour. And only use `FLAG_IS_CMDLINE` for issuing warnings to the user when we ergonomically change or ignore these values to be compatible.
> As well as adding the proper truncation for HeapSize incompatible values.
>
> * Testing
> * GHA
> * Tier 1-5 on Oracle Supported Platforms
This pull request has now been integrated.
Changeset: ce1adf63
Author: Axel Boldt-Christmas <aboldtch at openjdk.org>
URL: https://git.openjdk.org/jdk/commit/ce1adf63ea1146fba4cf36c10dc5f1d33aa88000
Stats: 73 lines in 1 file changed: 49 ins; 1 del; 23 mod
8371672: G1: G1YoungGenSizer handling of NewRatio, NewSize and MaxNewSize
8370494: G1: NewSize not bounded by InitialHeapSize or MaxHeapSize
Reviewed-by: tschatzl, iwalulya
-------------
PR: https://git.openjdk.org/jdk/pull/28255
More information about the hotspot-gc-dev
mailing list