RFR: 8296912: C2: CreateExNode::Identity fails with assert(i < _max) failed: oob: i=1, _max=1

Tobias Hartmann thartmann at openjdk.org
Wed Nov 16 12:28:04 UTC 2022


On Wed, 16 Nov 2022 12:00:34 GMT, Tobias Hartmann <thartmann at openjdk.org> wrote:

> The fix for [JDK-8284358](https://bugs.openjdk.org/browse/JDK-8284358) added code that aggressively removes dead subgraphs when detecting an unreachable Region by walking up the CFG and replacing all nodes by top (because they must be unreachable as well). In this case, we detect that `280 Region` is unreachable from root and replace `276 Catch` by top while walking up the CFG:
> 
> ![Screenshot from 2022-11-16 12-53-56](https://user-images.githubusercontent.com/5312595/202174104-9437914a-cb38-401c-b0fd-d6ca849969b0.png)
> 
> Code in `CreateExNode::Identity` does not expect `292 CatchProj` to have a top input when processing `305 CreateEx`. The fix is to simply add a `in(0)->in(0)->is_Catch()` check.
> 
> Thanks,
> Tobias

Thanks for the quick review, Christian!

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

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


More information about the hotspot-compiler-dev mailing list