RFR: 8371881: C2: Fix potential SEGV in VTransformReductionVectorNode tracing [v2]
Aleksey Shipilev
shade at openjdk.org
Fri Nov 14 17:11:03 UTC 2025
On Fri, 14 Nov 2025 15:59:32 GMT, Vishal Chand <duke at openjdk.org> wrote:
>> This PR fixes a potential SEGV and removes dead code:
>> • **Fix**: Prevent potential SEGV in VTransformReductionVectorNode - [from @shipilev] This fixes a crash in diagnostic code when isa_ReductionVector() unexpectedly returns nullptr. While this indicates the graph is already corrupted, the additional crash in `TRACE_OPTIMIZE` makes debugging harder. The fix adds defensive null checking to prevent the diagnostic crash and improve error handling.
>>
>> • **Cleanup**: Remove unused first_red variable
>
> Vishal Chand has updated the pull request incrementally with one additional commit since the last revision:
>
> Update src/hotspot/share/opto/vtransform.cpp
>
> Co-authored-by: Aleksey Shipilëv <shipilev at amazon.de>
Marked as reviewed by shade (Reviewer).
-------------
PR Review: https://git.openjdk.org/jdk/pull/28323#pullrequestreview-3465906006
More information about the hotspot-compiler-dev
mailing list