-
Enhancement
-
Resolution: Fixed
-
P4
-
16
-
b28
During the review of 8252221 the following suggestion came up:
I have another suggestion regarding "PreTouchParallelChunkSize" flag.
The default value looks huge and reducing this value to 128MB improved startup time for both G1GC and ParallelGC.
The following test are done with 1TB memory. Please see below.
time
./jdk/bin/java -XX:+AlwaysPreTouch -XX:-UseParallelGC -Xmx900g -Xms900g -Xmn800g -XX:SurvivorRatio=400 -Xlog:gc*=debug:file=gc.log -XX:ParallelGCThreads=128 -XX:PreTouchParallelChunkSize=1g -version
G1GC Test
ChunkSize= 1GB : Real time taken = 17.68s
ChunkSize= 128MB : Real time ttaken = 14.8s
ParallelGC Test
ChunkSize= 1GB : Real time taken = 13.54s
ChunkSize= 128MB : Real time taken = 12.8s
I.e.: improvements are in the range of
ParallelGC = 0.5-1 sec.
G1GC = 2-3 sec
Also, the minimum value allowed is '1' and it should be similar to page size right ?
See also https://mail.openjdk.java.net/pipermail/hotspot-gc-dev/2020-October/031711.html
I have another suggestion regarding "PreTouchParallelChunkSize" flag.
The default value looks huge and reducing this value to 128MB improved startup time for both G1GC and ParallelGC.
The following test are done with 1TB memory. Please see below.
time
./jdk/bin/java -XX:+AlwaysPreTouch -XX:-UseParallelGC -Xmx900g -Xms900g -Xmn800g -XX:SurvivorRatio=400 -Xlog:gc*=debug:file=gc.log -XX:ParallelGCThreads=128 -XX:PreTouchParallelChunkSize=1g -version
G1GC Test
ChunkSize= 1GB : Real time taken = 17.68s
ChunkSize= 128MB : Real time ttaken = 14.8s
ParallelGC Test
ChunkSize= 1GB : Real time taken = 13.54s
ChunkSize= 128MB : Real time taken = 12.8s
I.e.: improvements are in the range of
ParallelGC = 0.5-1 sec.
G1GC = 2-3 sec
Also, the minimum value allowed is '1' and it should be similar to page size right ?
See also https://mail.openjdk.java.net/pipermail/hotspot-gc-dev/2020-October/031711.html
- csr for
-
JDK-8257419 Suboptimal PreTouchParallelChunkSize defaults and limits
- Closed
- relates to
-
JDK-8257672 Improve PretouchParallelChunkSize for non-Linux platforms
- Open
-
JDK-8259380 Correct pretouch chunk size to cap with actual page size
- Resolved