From 1512d889dee2adb6d4536202dc7f205e5daf6fe7 Mon Sep 17 00:00:00 2001 From: Aleksey Shipilev Date: Fri, 19 Sep 2025 14:26:05 +0000 Subject: [PATCH] 8348278: Trim InitialRAMPercentage to improve startup in default modes Reviewed-by: eosterlund, sjohanss --- src/hotspot/share/gc/shared/gc_globals.hpp | 2 +- src/java.base/share/man/java.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/hotspot/share/gc/shared/gc_globals.hpp b/src/hotspot/share/gc/shared/gc_globals.hpp index 240068f10c0..0b245026d68 100644 --- a/src/hotspot/share/gc/shared/gc_globals.hpp +++ b/src/hotspot/share/gc/shared/gc_globals.hpp @@ -289,7 +289,7 @@ "size on systems with small physical memory size") \ range(0.0, 100.0) \ \ - product(double, InitialRAMPercentage, 1.5625, \ + product(double, InitialRAMPercentage, 0.2, \ "Percentage of real memory used for initial heap size") \ range(0.0, 100.0) \ \ diff --git a/src/java.base/share/man/java.md b/src/java.base/share/man/java.md index 1a6a944594f..d628cfee817 100644 --- a/src/java.base/share/man/java.md +++ b/src/java.base/share/man/java.md @@ -2448,7 +2448,7 @@ Java HotSpot VM. : Sets the initial amount of memory that the JVM will use for the Java heap before applying ergonomics heuristics as a percentage of the maximum amount determined as described in the `-XX:MaxRAM` option. The default value is - 1.5625 percent. + 0.2 percent. The following example shows how to set the percentage of the initial amount of memory used for the Java heap: