equal
deleted
inserted
replaced
23 |
23 |
24 /* |
24 /* |
25 * @test TestInitialTenuringThreshold |
25 * @test TestInitialTenuringThreshold |
26 * @key gc |
26 * @key gc |
27 * @bug 8014765 |
27 * @bug 8014765 |
|
28 * @requires vm.gc=="Parallel" |
28 * @summary Tests argument processing for initial tenuring threshold |
29 * @summary Tests argument processing for initial tenuring threshold |
29 * @library /testlibrary |
30 * @library /testlibrary |
30 * @modules java.base/sun.misc |
31 * @modules java.base/sun.misc |
31 * java.management |
32 * java.management |
32 * @run main/othervm TestInitialTenuringThreshold |
33 * @run main/othervm TestInitialTenuringThreshold |
37 |
38 |
38 public class TestInitialTenuringThreshold { |
39 public class TestInitialTenuringThreshold { |
39 |
40 |
40 public static void runWithThresholds(int initial, int max, boolean shouldfail) throws Exception { |
41 public static void runWithThresholds(int initial, int max, boolean shouldfail) throws Exception { |
41 ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( |
42 ProcessBuilder pb = ProcessTools.createJavaProcessBuilder( |
|
43 "-XX:+UseParallelGC", |
42 "-XX:InitialTenuringThreshold=" + String.valueOf(initial), |
44 "-XX:InitialTenuringThreshold=" + String.valueOf(initial), |
43 "-XX:MaxTenuringThreshold=" + String.valueOf(max), |
45 "-XX:MaxTenuringThreshold=" + String.valueOf(max), |
44 "-version" |
46 "-version" |
45 ); |
47 ); |
46 |
48 |