RFR: 8351216: ZGC: Store NUMA node count [v3]
Joel Sikström
jsikstro at openjdk.org
Thu Mar 13 09:02:39 UTC 2025
> To avoid calling into `os::Linux::max_numa_node()` and in turn libnuma on every count lookup, I propose we instead store the count statically inside ZNUMA. This is perfectly fine since the value that we get from libnuma is configured once during initialization and never change during runtime.
>
> The count is set during platform dependent initialization and the getter is now defined in the common code in ZNUMA.cpp. On operating systems that ZGC does not support NUMA for (BSD and Windows) we keep the current behavior by setting the count to 1.
>
> This is also preparation work for the Mapped Cache ([JDK-8350441](https://bugs.openjdk.org/browse/JDK-8350441)).
>
> Testing:
> * Tiers 1-3
> * GHA
> * Verify that the count is set on a Linux system with NUMA hardware
Joel Sikström has updated the pull request incrementally with one additional commit since the last revision:
Copyright years
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/23922/files
- new: https://git.openjdk.org/jdk/pull/23922/files/45dc106a..bdfcc781
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=23922&range=02
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=23922&range=01-02
Stats: 3 lines in 3 files changed: 0 ins; 0 del; 3 mod
Patch: https://git.openjdk.org/jdk/pull/23922.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/23922/head:pull/23922
PR: https://git.openjdk.org/jdk/pull/23922
More information about the hotspot-gc-dev
mailing list