[jdk21u-dev] RFR: 8313319: [linux] mmap should use MAP_FIXED_NOREPLACE if available

Thomas Stuefe stuefe at openjdk.org
Mon Nov 17 07:40:38 UTC 2025


On Fri, 14 Nov 2025 17:47:07 GMT, Sergey Chernyshev <schernyshev at openjdk.org> wrote:

> Hi all,
> 
> Please review the backport of JDK-8313319 that prevents unnecessary mmap-munmap cycle in systems that do not honor the address hint when mmapping memory without MAP_FIXED. Please see more details in #2475. This is (almost) a clean backport, with only a minor context conflict due to JDK-8315923 hasn't been backported to JDK 21.
> 
> Testing:
> 
> - jtreg standard test groups passed
> - gtests passed

Just to be clear, this downport's intent is performance, not outright failures, right? 

I only know of two cases where we rely on fixed addressing, ZGC being one of them. The other  would be class space reservation on Arm64. Do you see any other problems with the rand kernel patch outside of ZGC?

-------------

PR Comment: https://git.openjdk.org/jdk21u-dev/pull/2476#issuecomment-3540354812


More information about the jdk-updates-dev mailing list