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

JEP 165 (CompilerControl) changes break JMH @CompilerControl tests

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Verification:
      Verified

      Description

      (feel free to make this a subtask for JEP 165)

      The latest webrev from Nils:
        http://cr.openjdk.java.net/~neliasso/8046155/webrev.03/

      ...regresses JMH @CompilerControl tests.

      $ wget http://cr.openjdk.java.net/~shade/jmh/jmh-core-benchmarks.jar
      $ java -jar jmh-core-benchmarks.jar -t compiler_hints -m quick

      This is baseline JDK 9:

      --------- COMPILER HINTS TEST

        This tests verifies compiler hints are working as expected. Two baseline tests
        run the workloadin inlined and non-inlined regiments. When the workload is inlined,
        the optimizations should kill the workload body. Compiler hints should successfully
        survive in both regiments: INLINE should always inline, and DONT_INLINE should always
        break inlining. EXCLUDE should be neutral to inlining policy completely.

                                 Default inline policy: 0.25 ± 0.00 ns
                            + @CompilerControl(INLINE): 0.25 ± 0.00 ns
                       + @CompilerControl(DONT_INLINE): 17.91 ± 1.52 ns
                           + @CompilerControl(EXCLUDE): 59.53 ± 1.73 ns

                              Default no inline policy: 17.46 ± 0.02 ns
                            + @CompilerControl(INLINE): 0.25 ± 0.00 ns
                       + @CompilerControl(DONT_INLINE): 17.47 ± 0.06 ns
                           + @CompilerControl(EXCLUDE): 59.49 ± 0.38 ns

      And this is current JEP 165:

      --------- COMPILER HINTS TEST

        This tests verifies compiler hints are working as expected. Two baseline tests
        run the workloadin inlined and non-inlined regiments. When the workload is inlined,
        the optimizations should kill the workload body. Compiler hints should successfully
        survive in both regiments: INLINE should always inline, and DONT_INLINE should always
        break inlining. EXCLUDE should be neutral to inlining policy completely.

                                 Default inline policy: 49.90 ± 4.17 ns
                            + @CompilerControl(INLINE): 48.40 ± 0.15 ns
                       + @CompilerControl(DONT_INLINE): 48.34 ± 0.15 ns
                           + @CompilerControl(EXCLUDE): 48.42 ± 0.24 ns

                              Default no inline policy: 26.31 ± 0.10 ns
                            + @CompilerControl(INLINE): 26.41 ± 0.29 ns
                       + @CompilerControl(DONT_INLINE): 26.34 ± 0.21 ns
                           + @CompilerControl(EXCLUDE): 26.31 ± 0.09 ns


        Attachments

          Issue Links

            Activity

              People

              Assignee:
              neliasso Nils Eliasson
              Reporter:
              shade Aleksey Shipilev
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: