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

Loop unswitching may cause out of bound array load to be executed

    Details

    • Subcomponent:
    • Resolved In Build:
      b17

      Backports

        Description

        This came up with testing of JDK-8223051:

        https://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/2020-August/039801.html

        A loop is unswitched then a pre/post loop is created and finally the main loop is fully unrolled. A load in the main loop floats above the unswitching test and is executed even though it's out of bound (the main loop wouldn't have been executed). This doesn't seem specific to JDK-8223051 even though I couldn't write a test case that reproduces it with current jdk code.

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  roland Roland Westrelin
                  Reporter:
                  roland Roland Westrelin
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  5 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: