RFR: 8365604: Null pointer dereference in src/hotspot/share/adlc/output_h.cpp ArchDesc::declareClasses() [v2]
Artem Semenov
asemenov at openjdk.org
Thu Aug 21 09:01:12 UTC 2025
> The defect has been detected and confirmed in the function ArchDesc::declareClasses() located in the file src/hotspot/share/adlc/output_h.cpp with static code analysis. This defect can potentially lead to a null pointer dereference.
>
> The pointer instr->_matrule is dereferenced in line 1952 without checking for nullptr, although earlier in line 1858 the same pointer is checked for nullptr, which indicates that it can be null.
>
> According to [this](https://github.com/openjdk/jdk/pull/26002#issuecomment-3023050372) comment, this PR contains fixes for similar cases in other places.
Artem Semenov has updated the pull request incrementally with two additional commits since the last revision:
- Update src/hotspot/share/c1/c1_LinearScan.cpp
Co-authored-by: David Holmes <62092539+dholmes-ora at users.noreply.github.com>
- Update src/hotspot/share/adlc/output_h.cpp
Co-authored-by: David Holmes <62092539+dholmes-ora at users.noreply.github.com>
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/26798/files
- new: https://git.openjdk.org/jdk/pull/26798/files/80777ced..dd21148b
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=26798&range=01
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=26798&range=00-01
Stats: 2 lines in 2 files changed: 0 ins; 0 del; 2 mod
Patch: https://git.openjdk.org/jdk/pull/26798.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/26798/head:pull/26798
PR: https://git.openjdk.org/jdk/pull/26798
More information about the hotspot-jfr-dev
mailing list