Support for Windows large pages in Intel/AMD
Thomas Stüfe
thomas.stuefe at gmail.com
Mon Oct 16 16:07:09 UTC 2023
Hi Nitin,
did you maybe miss read David and Stefans elaborations on this?
https://mail.openjdk.org/pipermail/hotspot-runtime-dev/2023-October/065361.html
Cheers, Thomas
On Mon, Oct 16, 2023 at 5:35 PM Nitin Singh <singhnitin at microsoft.com>
wrote:
> Hello OpenJDK Community,
>
> I've been immersing myself in understanding large pages within OpenJDK,
> especially for the Windows OS. Here's an observation I'd like to share and
> seek feedback on.
>
> It appears that on Windows Server 2022 Datacenter (OS Version:
> 10.0.20348), when employing AMD or Intel processors, there's an implicit
> restriction that limits the use of large page sizes to 4MB. This constraint
> seems to originate from line 3199 in os_windows.cpp
>
>
> https://github.com/openjdk/jdk/blob/2e340e855b760e381793107f2a4d74095bd40199/src/hotspot/os/windows/os_windows.cpp#L3199.
>
> To probe this further, I tweaked the code to see what would happen without
> this restriction. The results were enlightening. I was able to successfully
> use an 8MB large page size, and my subsequent benchmarks post this change
> have been quite positive.
>
> What heightens my curiosity is the knowledge that these processors support
> up to 1G of large pages (HugeTLB pages). Given the widespread support for
> these processors by various cloud providers, it does feel like we're
> missing out on potential optimizations for HotSpot running on Windows.
>
> Before delving deeper, I'd love to get some historical context. Can anyone
> share insights about why this 4MB limit was imposed in the first place?
> Were there specific technical challenges or concerns that led to this
> decision?
>
> I'm currently working with the Microsoft JDK version
> microsoft-jdk-17.0.8-windows-x64.
>
> Thank you for shedding light on this matter. I deeply appreciate your
> guidance as I tread these waters.
>
> Thanks,
>
> Nitin Singh
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/hotspot-runtime-dev/attachments/20231016/56bf14c7/attachment.htm>
More information about the hotspot-runtime-dev
mailing list