RFR: 8342504: Remove NMT header and footer canaries
Johan Sjölen
jsjolen at openjdk.org
Thu Oct 17 13:08:44 UTC 2024
Today NMT has two canaries: A header and a footer canary. These enable mainly two things:
1. For NMT to aid in describing a pointer
2. A basic form of out-of-bounds protection
With the introduction of UBSan and Asan into OpenJDK we have gained stronger tools for this sort of analysis, without requiring NMT to be activated. Therefore, I believe that point 2 is no longer something that NMT needs to support. For point number one, we will unfortunately be losing this ability.
I want to delete these canaries to open up a few free bytes. These can allow us to have "practically unlimited" (4 bytes) of memory tags.
tier1-tier2 tests succeeded.
I am awaiting discussion on the Hotspot-dev mailing list, but keeping this PR open for review.
-------------
Commit messages:
- Remove canaries
Changes: https://git.openjdk.org/jdk/pull/21560/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=21560&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8342504
Stats: 361 lines in 8 files changed: 0 ins; 349 del; 12 mod
Patch: https://git.openjdk.org/jdk/pull/21560.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/21560/head:pull/21560
PR: https://git.openjdk.org/jdk/pull/21560
More information about the hotspot-runtime-dev
mailing list