Integrated: 8298824: C2 crash: assert(is_Bool()) failed: invalid node class: ConI

Christian Hagedorn chagedorn at openjdk.org
Mon Dec 19 07:13:58 UTC 2022


On Fri, 16 Dec 2022 09:37:26 GMT, Christian Hagedorn <chagedorn at openjdk.org> wrote:

> [JDK-8292889](https://bugs.openjdk.org/browse/JDK-8292289) added the following optimization to `BoolNode::Ideal()` for patterns that include `CMoveI` nodes:
> 
> https://github.com/openjdk/jdk/blob/fa322e40b68abf0a253040d14414d41f4e01e028/src/hotspot/share/opto/subnode.cpp#L1465-L1472
> 
> However, we could have a `CMoveI` during IGVN that will later be folded because the `Bool` condition node was replaced by a constant but IGVN has not processed this node, yet:
> 
>  
> ![Screenshot from 2022-12-16 09-40-28](https://user-images.githubusercontent.com/17833009/208068197-4819b322-604c-412e-8898-3d3546a8a663.png)
> 
> We fail when trying to call `as_Bool()` on `28 ConI`. The fix is straight forward to additionally check if we actually have a `BoolNode`.
> 
> Thanks,
> Christian

This pull request has now been integrated.

Changeset: 5e678f75
Author:    Christian Hagedorn <chagedorn at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/5e678f7500e514f04637c546959613d4688f989c
Stats:     53 lines in 2 files changed: 52 ins; 0 del; 1 mod

8298824: C2 crash: assert(is_Bool()) failed: invalid node class: ConI

Reviewed-by: roland, kvn, thartmann

-------------

PR: https://git.openjdk.org/jdk/pull/11705


More information about the hotspot-compiler-dev mailing list