The NUMA allocation support in ZGC works as expected only when using -XX:+UseLargePages. The reason is that, on Linux, small pages are allocated at commit/fallocate time and is controlled by the NUMA policy of the current thread, while large pages are allocated at page fault time and is controlled by the NUMA policy of the memory range. ZGC currently only sets up the NUMA policy for the memory range, which has no effect on small pages (since they are allocated by tmpfs rather than being anonymous mappings).
We should fix this, so that the NUMA allocation support works equally well for small pages.
We should fix this, so that the NUMA allocation support works equally well for small pages.
- relates to
-
JDK-8266681 ZGC: Select nearest numa node in ZGC
- Open
- links to
-
Commit openjdk/panama-foreign/91d58b8f