RFR: 8318817: Could not reserve enough space in CodeHeap 'profiled nmethods' (0K) [v2]
Roberto Castañeda Lozano
rcastanedalo at openjdk.org
Tue Oct 31 10:53:30 UTC 2023
On Tue, 31 Oct 2023 08:23:29 GMT, Daniel Lundén <duke at openjdk.org> wrote:
> maybe os::vm_allocation_granularity() >= os::vm_page_size() is always true?
I just checked and this holds on Windows (64 bits): `os::vm_page_size()` gives 4K and `os::vm_allocation_granularity()` gives 64K regardless of whether `UseLargePages` is set (this option affects the value of `ps` only). On all other OS:es we have `os::vm_allocation_granularity() == os::vm_page_size()` so it should be safe to remove `os::vm_page_size()`, right?
Perhaps you can remove it but add an assertion that it is always equal or smaller to `MAX2(os::vm_allocation_granularity(), ps)`.
Also, I think it would be good to include a Windows-specific test case to exercise the case where `os::vm_allocation_granularity() != os::vm_page_size()`, would this be possible?
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/16373#discussion_r1377399460
More information about the hotspot-compiler-dev
mailing list