RFR: 8276055: ZGC: Defragment address space
Per Liden
pliden at openjdk.java.net
Wed Oct 27 12:19:24 UTC 2021
In ZGC, small pages are allocated from the beginning of the address space (low addresses), while medium and large pages are allocated from the end of the address space (high addresses). However, small pages can sometimes end up on a high address if a medium or a large page was split into small pages. Over time this can cause the address space to become fragmented, with the risk of eventually running out of address space for new large allocations.
To mitigate this, we can defragment the address space by letting small pages at high addresses be remapped to lower addresses. That's what this patch does.
Testing:
- Tier 1-7 with ZGC on Linux/x86_64
- SPECjbb2015 shows no regression
- Manuel ran test that tries to fragment the address space
-------------
Commit messages:
- 8276055: ZGC: Defragment address space
Changes: https://git.openjdk.java.net/jdk/pull/6137/files
Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=6137&range=00
Issue: https://bugs.openjdk.java.net/browse/JDK-8276055
Stats: 69 lines in 7 files changed: 63 ins; 0 del; 6 mod
Patch: https://git.openjdk.java.net/jdk/pull/6137.diff
Fetch: git fetch https://git.openjdk.java.net/jdk pull/6137/head:pull/6137
PR: https://git.openjdk.java.net/jdk/pull/6137
More information about the hotspot-gc-dev
mailing list