[jdk21u-dev] RFR: 8338136: Hotspot should support multiple large page sizes on Windows
Dhamoder Nalla
dhanalla at openjdk.org
Tue Mar 25 16:52:36 UTC 2025
This pull request introduces enhancements to the handling of large page sizes in the OpenJDK for Windows systems, aiming to align its capabilities with those observed on Linux platforms. Investigation through SPECJBB benchmarks across various platforms revealed a 16-year-old limitation in handling large pages over 4MB for IA32/AMD64 architectures, with no such constraints for Windows on ARM64.
JBS issue https://bugs.openjdk.org/browse/JDK-8338136
The goal of this change is to overcome the 4MB large page size limitation, thereby enhancing Windows' large page support to match Linux's more flexible handling capabilities. This decision to remove 4MB constraint was influenced by insights from Linux's implementation strategies. The implementation supports multiple large page sizes , specifically excluding the IA32 architecture.
Key changes and bug fixes include enabling Windows support for multiple huge page sizes with -XX:LargePageSizeInBytes, and utilizing logic from [JDK-8271195](https://bugs.openjdk.org/browse/JDK-8271195) to use the largest available large page size smaller than LargePageSizeInBytes when available.
This update removes the 4MB limit on AMD64 for Windows, populating the shared array to enable fallback options on all architectures except IA32. The implementation introduces an experimental flag, defaulting to FALSE, to facilitate testing and gradual adoption of these changes. The flag allows users to opt-in to the new large page handling logic, with a warning mechanism implemented for cases where the requested large page size is not a multiple of the OS minimum page size.
-------------
Commit messages:
- Backport 4ded28380b6756e0679d80706f76bd6e78c370b9
Changes: https://git.openjdk.org/jdk21u-dev/pull/1547/files
Webrev: https://webrevs.openjdk.org/?repo=jdk21u-dev&pr=1547&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8338136
Stats: 154 lines in 4 files changed: 142 ins; 1 del; 11 mod
Patch: https://git.openjdk.org/jdk21u-dev/pull/1547.diff
Fetch: git fetch https://git.openjdk.org/jdk21u-dev.git pull/1547/head:pull/1547
PR: https://git.openjdk.org/jdk21u-dev/pull/1547
More information about the jdk-updates-dev
mailing list