8376421: C2: Missing branch on SubTypeCheck node#30573
8376421: C2: Missing branch on SubTypeCheck node#30573iwanowww wants to merge 1 commit intoopenjdk:masterfrom
Conversation
|
👋 Welcome back vlivanov! A progress list of the required criteria for merging this PR into |
|
@iwanowww This change now passes all automated pre-integration checks. ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details. After integration, the commit message for the final commit will be: You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed. At the time when this comment was updated there had been 29 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details. ➡️ To integrate this PR with the above commit message to the |
SubTypeCheckrelies on custom logic to detect when the operation is redundant during GVN while subsequentCheckCastPPoninstanceofsuccess branch (introduced by JDK-8372634) uses C2 type system.It turns out the latter is superior and the bug demonstrates one case when C2 proves that receiver type after the check is empty while
Compile::static_subtype_check()doesn't report correspondingSubTypeCheckas redundant. It leaves the branch im corrupted state with a single control projection.Proposed fix piggybacks on control pruning for dead type nodes introduced by JDK-8349479. It keeps the redundant runtime check, but places a
Haltnode on pruned branch thus preserving CFG correctness.I filed an RFE (JDK-8381646) to improve the analysis performed by
SubTypeChecknode during GVN.Testing: hs-tier1 - hs-tier5
Thanks!
Progress
Issue
Reviewers
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/30573/head:pull/30573$ git checkout pull/30573Update a local copy of the PR:
$ git checkout pull/30573$ git pull https://git.openjdk.org/jdk.git pull/30573/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 30573View PR using the GUI difftool:
$ git pr show -t 30573Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/30573.diff
Using Webrev
Link to Webrev Comment