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

C2 incorrectly folds subtype checks involving an interface array

    XMLWordPrintable

Details

    • b23
    • Verified

    Backports

      Description

        ADDITIONAL SYSTEM INFORMATION :
        JDK: 11.0.11

        A DESCRIPTION OF THE PROBLEM :
        JDK: 11.0.11
        Minimum Reproducible Code: https://github.com/chhsiao90/jdk-8257594-bug

        When running the main function of PropertyInfoSetResolver, java.lang.ClassCastException was thrown while several iterations.

        Bug is only reproducible on 11.0.11 and 16.0.1.
        It looks like it's JIT optimization issue, might be introduced by https://bugs.openjdk.java.net/browse/JDK-8257594

        STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
        Clones the git repository from github: https://github.com/chhsiao90/jdk-8257594-bug
        Run the main function of PropertyInfoSetResolver

        EXPECTED VERSUS ACTUAL BEHAVIOR :
        EXPECTED -
        Run without error
        ACTUAL -
        java.lang.ClassCastException after several iteration

        ---------- BEGIN SOURCE ----------
        https://github.com/chhsiao90/jdk-8257594-bug
        ---------- END SOURCE ----------

        CUSTOMER SUBMITTED WORKAROUND :
        Downgrade JDK to 11.0.10

        FREQUENCY : always


        Attachments

          1. Test.java
            0.6 kB
          2. protobuf-java-3.11.4.jar
            1.58 MB
          3. modelmapper-2.3.0.jar
            3.52 MB
          4. JDK11011Defect.java
            6 kB

          Issue Links

            Activity

              People

                thartmann Tobias Hartmann
                webbuggrp Webbug Group
                Votes:
                0 Vote for this issue
                Watchers:
                8 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: