[jdk18] RFR: 8271202 C1: assert(false) failed: live_in set of first block must be empty

Igor Veresov iveresov at openjdk.java.net
Fri Dec 24 19:28:49 UTC 2021


The root cause seems to be because of the irreducible loops (and therefore an unusual block traversal order when inserting phis) the phi invalidation logic in try_merge() doesn't invalidate phis that have invalid locals as inputs. I've attached a drawing: [8271202.pdf](https://github.com/openjdk/jdk18/files/7775050/8271202.pdf). Notice that i54 = phi (i43, 96) is not invalidated even though 96 is illegal. Transitively, i43, it should be illegal too. I would propose that we add a check for that and bailout in move_phi().

This has also been discussed here: https://github.com/openjdk/jdk/pull/6683

Testing is clean.

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

Commit messages:
 - Bailout in case live range extension produces invalid phi

Changes: https://git.openjdk.java.net/jdk18/pull/73/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk18&pr=73&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8271202
  Stats: 75 lines in 2 files changed: 75 ins; 0 del; 0 mod
  Patch: https://git.openjdk.java.net/jdk18/pull/73.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk18 pull/73/head:pull/73

PR: https://git.openjdk.java.net/jdk18/pull/73


More information about the hotspot-compiler-dev mailing list