RFR: 8361487: [ubsan] test_committed_virtualmemory.cpp check_covered_pages shows overflow [v3]
Afshin Zafari
azafari at openjdk.org
Thu Nov 13 13:34:55 UTC 2025
> In the test, page-numbers to be checked are passed to a checker function in which they will be changed to `-1` if they are as expected.
> Use of these `-1` values for page-numbers in consequent checks result in overflow in pointer arithmetic of `base + (-1) * page_size` which is certainly less than `base`.
>
> The fix is to skip cases where page-number under checking is `-1`.
> Tested under UBSAN build.
Afshin Zafari has updated the pull request incrementally with one additional commit since the last revision:
better comment
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/28151/files
- new: https://git.openjdk.org/jdk/pull/28151/files/d45208dc..f3f3fe0e
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=28151&range=02
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=28151&range=01-02
Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
Patch: https://git.openjdk.org/jdk/pull/28151.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/28151/head:pull/28151
PR: https://git.openjdk.org/jdk/pull/28151
More information about the hotspot-runtime-dev
mailing list