< prev index next >

test/hotspot/jtreg/runtime/logging/SafepointCleanupTest.java

Print this page
rev 60025 : 8246476: remove AsyncDeflateIdleMonitors option and the safepoint based deflation mechanism

@@ -27,27 +27,21 @@
  * @summary safepoint+cleanup=info should have output from the code
  * @library /test/lib
  * @modules java.base/jdk.internal.misc
  *          java.management
  * @run driver SafepointCleanupTest
- * @run driver SafepointCleanupTest -XX:+AsyncDeflateIdleMonitors
  */
 
 import jdk.test.lib.process.OutputAnalyzer;
 import jdk.test.lib.process.ProcessTools;
 
 public class SafepointCleanupTest {
-    static final String ASYNC_DISABLE_OPTION = "-XX:-AsyncDeflateIdleMonitors";
-    static final String ASYNC_ENABLE_OPTION = "-XX:+AsyncDeflateIdleMonitors";
-    static final String UNLOCK_DIAG_OPTION = "-XX:+UnlockDiagnosticVMOptions";
-
     static void analyzeOutputOn(ProcessBuilder pb) throws Exception {
         OutputAnalyzer output = new OutputAnalyzer(pb.start());
         output.shouldContain("[safepoint,cleanup]");
         output.shouldContain("safepoint cleanup tasks");
-        output.shouldContain("deflating global idle monitors");
-        output.shouldContain("deflating per-thread idle monitors");
+        output.shouldContain("deflating idle monitors");
         output.shouldContain("updating inline caches");
         output.shouldContain("compilation policy safepoint handler");
         output.shouldHaveExitValue(0);
     }
 

@@ -56,44 +50,23 @@
         output.shouldNotContain("[safepoint,cleanup]");
         output.shouldHaveExitValue(0);
     }
 
     public static void main(String[] args) throws Exception {
-        String async_option;
-        if (args.length == 0) {
-            // By default test deflating idle monitors at a safepoint.
-            async_option = ASYNC_DISABLE_OPTION;
-        } else {
-            async_option = args[0];
-        }
-        if (!async_option.equals(ASYNC_DISABLE_OPTION) &&
-            !async_option.equals(ASYNC_ENABLE_OPTION)) {
-            throw new RuntimeException("Unknown async_option value: '"
-                                       + async_option + "'");
-        }
-
         ProcessBuilder pb = ProcessTools.createJavaProcessBuilder("-Xlog:safepoint+cleanup=info",
-                                                                  UNLOCK_DIAG_OPTION,
-                                                                  async_option,
                                                                   InnerClass.class.getName());
         analyzeOutputOn(pb);
 
         pb = ProcessTools.createJavaProcessBuilder("-XX:+TraceSafepointCleanupTime",
-                                                   UNLOCK_DIAG_OPTION,
-                                                   async_option,
                                                    InnerClass.class.getName());
         analyzeOutputOn(pb);
 
         pb = ProcessTools.createJavaProcessBuilder("-Xlog:safepoint+cleanup=off",
-                                                   UNLOCK_DIAG_OPTION,
-                                                   async_option,
                                                    InnerClass.class.getName());
         analyzeOutputOff(pb);
 
         pb = ProcessTools.createJavaProcessBuilder("-XX:-TraceSafepointCleanupTime",
-                                                   UNLOCK_DIAG_OPTION,
-                                                   async_option,
                                                    InnerClass.class.getName());
         analyzeOutputOff(pb);
     }
 
     public static class InnerClass {
< prev index next >