Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8292285

C2: remove unreachable block after NeverBranch-to-Goto conversion

    XMLWordPrintable

Details

    • b11

    Backports

      Description

        NeverBranch nodes introduce fake branches out of infinite loops to simplify intermediate optimizations that assume full reachability (see before.pdf). 'PhaseCFG::convert_NeverBranch_to_Goto()' transforms such nodes into simple Goto nodes, removing the fake branch and thus making its destination block unreachable (see after.pdf).

        This RFE proposes removing the unreachable destination block created by 'PhaseCFG::convert_NeverBranch_to_Goto()' from the list of basic blocks (see after-removal.pdf). Removing the unreachable block simplifies late control-flow analysis (for example, recomputing dominators during the output phase as required for late barrier analysis in Generational ZGC) and slightly reduces the size of the resulting nmethod.

        Attachments

          1. after.pdf
            6 kB
          2. after-removal.pdf
            5 kB
          3. before.pdf
            7 kB

          Issue Links

            Activity

              People

                rcastanedalo Roberto Castaneda Lozano
                rcastanedalo Roberto Castaneda Lozano
                Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: