RFR: 8344824: CDS dump crashes when member_method of a lambda proxy is null
Ioi Lam
iklam at openjdk.org
Fri Nov 22 05:47:51 UTC 2024
Since [JDK-8335583](https://bugs.openjdk.org/browse/JDK-8335583), we encode 64-bit pointers used by `RunTimeLambdaProxyClassKey` into 32-bit offsets. However, we didn't handle the cases where some of the pointers could be null.
In this PR, I have added an `or_null` variant of the functions that deal with pointer-to-offset encoding. The `or_null` variant allows an `nullptr` to be encoded with the 32-bit value of `0`.
I also renamed some of the functions to improve readability.
-------------
Commit messages:
- 8344824: CDS dump crashes when member_method of a lambda proxy is null
Changes: https://git.openjdk.org/jdk/pull/22313/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=22313&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8344824
Stats: 162 lines in 7 files changed: 143 ins; 4 del; 15 mod
Patch: https://git.openjdk.org/jdk/pull/22313.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/22313/head:pull/22313
PR: https://git.openjdk.org/jdk/pull/22313
More information about the hotspot-runtime-dev
mailing list