hotspot/test/compiler/rtm/locking/TestRTMLockingThreshold.java
changeset 41092 c388d897472d
parent 40855 3c4c913195e3
child 41330 8b2580e63aa0
equal deleted inserted replaced
41091:de3789bb384e 41092:c388d897472d
    47 import compiler.testlibrary.rtm.predicate.SupportedCPU;
    47 import compiler.testlibrary.rtm.predicate.SupportedCPU;
    48 import compiler.testlibrary.rtm.predicate.SupportedVM;
    48 import compiler.testlibrary.rtm.predicate.SupportedVM;
    49 import jdk.internal.misc.Unsafe;
    49 import jdk.internal.misc.Unsafe;
    50 import jdk.test.lib.Asserts;
    50 import jdk.test.lib.Asserts;
    51 import jdk.test.lib.process.OutputAnalyzer;
    51 import jdk.test.lib.process.OutputAnalyzer;
    52 import jdk.test.lib.unsafe.UnsafeHelper;
       
    53 import jdk.test.lib.cli.CommandLineOptionTest;
    52 import jdk.test.lib.cli.CommandLineOptionTest;
    54 import jdk.test.lib.cli.predicate.AndPredicate;
    53 import jdk.test.lib.cli.predicate.AndPredicate;
    55 
    54 
    56 import java.util.List;
    55 import java.util.List;
    57 
    56 
   140     public static class Test implements CompilableTest {
   139     public static class Test implements CompilableTest {
   141         // Following field have to be static in order to avoid escape analysis.
   140         // Following field have to be static in order to avoid escape analysis.
   142         @SuppressWarnings("UnsuedDeclaration")
   141         @SuppressWarnings("UnsuedDeclaration")
   143         private static int field = 0;
   142         private static int field = 0;
   144         private static final int TOTAL_ITERATIONS = 10000;
   143         private static final int TOTAL_ITERATIONS = 10000;
   145         private static final Unsafe UNSAFE = UnsafeHelper.getUnsafe();
   144         private static final Unsafe UNSAFE = Unsafe.getUnsafe();
   146         private final Object monitor = new Object();
   145         private final Object monitor = new Object();
   147 
   146 
   148 
   147 
   149         @Override
   148         @Override
   150         public String getMethodWithLockName() {
   149         public String getMethodWithLockName() {