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

C2: Enable optimization again after JDK-8314307

XMLWordPrintable

      compiler/c2/irTests/TestDuplicateBackedge.java fails after JDK-8314307 (was problemlisted). The problem is the following:

      PhaseIdealLoop::duplicate_loop_backedge() splits a loop that cannot be transformed to a counted loop into an inner and outer loop. The idea is that the inner loop can then be converted into a counted loop afterward.

      However, this is no longer possible after JDK-8314307 due to requiring a Loop Limit Check Predicate (with a Loop Limit Check Parse Predicate) for the inner loop because we cannot statically prove that there is no overflow. We can only transform the loop to a counted loop if we have a guarantee that there is no overflow.

      After duplicate_loop_backedge(), we have Loop -> Loop without any Parse Predicate in between. We fail to transform the inner loop to a counted loop and the IR matching done in TestDuplicateBackedge fails. We should try to fix this.

            roland Roland Westrelin
            chagedorn Christian Hagedorn
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: