Integrated: 8319795: Static huge pages are not used for CodeCache

Evgeny Astigeevich eastigeevich at openjdk.org
Thu Dec 21 18:54:54 UTC 2023


On Thu, 9 Nov 2023 15:20:26 GMT, Evgeny Astigeevich <eastigeevich at openjdk.org> wrote:

> This is a fix of a regression introduced by [JDK-8261894](https://bugs.openjdk.org/browse/JDK-8261894).
> After JDK-8261894, `os::can_execute_large_page_memory()` returns `true` only if `UseTransparentHugePages` is true. As CodeCache uses `os::can_execute_large_page_memory()` when it detects a page size, CodeCache cannot use static huge pages (`UseTransparentHugePages` is `false`) anymore after the change.
> Before JDK-8261894, `os::can_execute_large_page_memory()` returned `true`  when either `UseTransparentHugePages` or `UseHugeTLBFS` was true.
> 
> After JDK-8261894, `XX:+UseLargePages XX:-UseTransparentHugePages` means to use static huge pages: aka `UseHugeTLBFS` is `true`. If `UseLargePages` is not set to `true` via the option, it will be set to `true` if `UseTransparentHugePages` is `true`.
> 
> `os::can_execute_large_page_memory()` is modified to return `UseLargePages`. A regression gtest  is added.
> 
> Tested fastdebug and release builds:
> - [x] tier1
> - [x] gtest
> - [x] test/hotspot/jtreg/gtest/LargePageGtests.java

This pull request has now been integrated.

Changeset: 3b908c47
Author:    Evgeny Astigeevich <eastigeevich at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/3b908c478186cbfd9d449422aaa5adacd5e5c2d4
Stats:     129 lines in 8 files changed: 71 ins; 48 del; 10 mod

8319795: Static huge pages are not used for CodeCache

Reviewed-by: shade, simonis, thartmann, stuefe

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

PR: https://git.openjdk.org/jdk/pull/16582


More information about the hotspot-runtime-dev mailing list