RFR: 8326638: Crash in PhaseIdealLoop::remix_address_expressions due to unexpected Region instead of Loop
Tobias Hartmann
thartmann at openjdk.org
Mon Feb 26 08:40:05 UTC 2024
Adds a missing `_head->is_Loop()` check to handle the case when the loop head is not a `LoopNode` but a `RegionNode` because the loop is irreducible:
(rr) p n_loop->_head->dump(1)
412 IfTrue === 411 [[ 345 ]] #1 !jvms: Test$Class1::Class1_method0 @ bci:286 (line 119)
339 SafePoint === 336 1 340 1 1 344 290 1 1 1 1 291 1 1 293 294 295 1 320 297 1 298 299 300 301 302 1 303 1 [[ 345 ]] SafePoint !jvms: Test$Class1::Class1_method0 @ bci:307 (line 122)
345 Region === 345 339 412 [[ 345 456 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 1861 1863 1865 1867 1882 1888 ]] #irreducible !jvms: Test$Class1::Class1_method0 @ bci:138 (line 101)
We then crash when invoking `LoopNode::skip_strip_mined` on a RegionNode or assert in debug. Unfortunately, I was not able to simply the test any further.
This is a regression from [JDK-8303511](https://bugs.openjdk.org/browse/JDK-8303511) in JDK 21 b13
Thanks,
Tobias
-------------
Commit messages:
- Removed whitespace
- Missing comment
- Added test
- 8326638: Crash in PhaseIdealLoop::remix_address_expressions due to unexpected Region instead of Loop
Changes: https://git.openjdk.org/jdk/pull/18002/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=18002&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8326638
Stats: 64 lines in 2 files changed: 61 ins; 0 del; 3 mod
Patch: https://git.openjdk.org/jdk/pull/18002.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/18002/head:pull/18002
PR: https://git.openjdk.org/jdk/pull/18002
More information about the hotspot-compiler-dev
mailing list