< prev index next >

test/compiler/rtm/locking/TestRTMLockingCalculationDelay.java

Print this page




  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 /**
  26  * @test
  27  * @bug 8031320
  28  * @summary Verify that RTMLockingCalculationDelay affect when
  29  *          abort ratio calculation is started.
  30  * @library /testlibrary /../../test/lib /compiler/testlibrary
  31  * @modules java.base/sun.misc
  32  *          java.management
  33  * @build TestRTMLockingCalculationDelay
  34  * @run main ClassFileInstaller sun.hotspot.WhiteBox
  35  *                              sun.hotspot.WhiteBox$WhiteBoxPermission
  36  * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions
  37  *                   -XX:+WhiteBoxAPI TestRTMLockingCalculationDelay
  38  */
  39 
  40 import com.oracle.java.testlibrary.*;
  41 import com.oracle.java.testlibrary.cli.CommandLineOptionTest;
  42 import com.oracle.java.testlibrary.cli.predicate.AndPredicate;
  43 import rtm.*;
  44 import rtm.predicate.SupportedCPU;
  45 import rtm.predicate.SupportedVM;
  46 
  47 /**
  48  * Test verifies that abort ratio calculation could be delayed using
  49  * RTMLockingCalculationDelay option.
  50  */
  51 public class TestRTMLockingCalculationDelay extends CommandLineOptionTest {
  52     private static final boolean INFLATE_MONITOR = true;
  53 
  54     private TestRTMLockingCalculationDelay() {
  55         super(new AndPredicate(new SupportedCPU(), new SupportedVM()));
  56     }
  57 
  58     @Override
  59     protected void runTestCases() throws Throwable {
  60         // verify that calculation will be started immediately
  61         verifyLockingCalculationDelay(0, 0, true);
  62 




  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 /**
  26  * @test
  27  * @bug 8031320
  28  * @summary Verify that RTMLockingCalculationDelay affect when
  29  *          abort ratio calculation is started.
  30  * @library /testlibrary /../../test/lib /compiler/testlibrary
  31  * @modules java.base/sun.misc
  32  *          java.management
  33  * @build TestRTMLockingCalculationDelay
  34  * @run main ClassFileInstaller sun.hotspot.WhiteBox
  35  *                              sun.hotspot.WhiteBox$WhiteBoxPermission
  36  * @run main/othervm -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions
  37  *                   -XX:+WhiteBoxAPI TestRTMLockingCalculationDelay
  38  */
  39 
  40 import jdk.test.lib.*;
  41 import jdk.test.lib.cli.CommandLineOptionTest;
  42 import jdk.test.lib.cli.predicate.AndPredicate;
  43 import rtm.*;
  44 import rtm.predicate.SupportedCPU;
  45 import rtm.predicate.SupportedVM;
  46 
  47 /**
  48  * Test verifies that abort ratio calculation could be delayed using
  49  * RTMLockingCalculationDelay option.
  50  */
  51 public class TestRTMLockingCalculationDelay extends CommandLineOptionTest {
  52     private static final boolean INFLATE_MONITOR = true;
  53 
  54     private TestRTMLockingCalculationDelay() {
  55         super(new AndPredicate(new SupportedCPU(), new SupportedVM()));
  56     }
  57 
  58     @Override
  59     protected void runTestCases() throws Throwable {
  60         // verify that calculation will be started immediately
  61         verifyLockingCalculationDelay(0, 0, true);
  62 


< prev index next >