< prev index next >

test/gc/arguments/TestObjectTenuringFlags.java

Print this page

        

*** 46,56 **** // valid cases runTenuringFlagsConsistencyTest( new String[]{"-XX:+NeverTenure"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, true /* neverTenure */, 7, 16)); runTenuringFlagsConsistencyTest( new String[]{"-XX:+AlwaysTenure"}, false /* shouldFail */, new ExpectedTenuringFlags(true /* alwaysTenure */, false /* neverTenure */, 0, 0)); --- 46,56 ---- // valid cases runTenuringFlagsConsistencyTest( new String[]{"-XX:+NeverTenure"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, true /* neverTenure */, 7, 32)); runTenuringFlagsConsistencyTest( new String[]{"-XX:+AlwaysTenure"}, false /* shouldFail */, new ExpectedTenuringFlags(true /* alwaysTenure */, false /* neverTenure */, 0, 0));
*** 69,86 **** new String[]{"-XX:MaxTenuringThreshold=10"}, false /* shouldFail */, new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 7, 10)); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:MaxTenuringThreshold=15"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 7, 15)); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:MaxTenuringThreshold=16"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 7, 16)); runTenuringFlagsConsistencyTest( new String[]{"-XX:InitialTenuringThreshold=0"}, false /* shouldFail */, new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 0, 15)); --- 69,86 ---- new String[]{"-XX:MaxTenuringThreshold=10"}, false /* shouldFail */, new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 7, 10)); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:MaxTenuringThreshold=31"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 7, 31)); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:MaxTenuringThreshold=32"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 7, 32)); runTenuringFlagsConsistencyTest( new String[]{"-XX:InitialTenuringThreshold=0"}, false /* shouldFail */, new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 0, 15));
*** 102,151 **** // "Last option wins" cases runTenuringFlagsConsistencyTest( new String[]{"-XX:+AlwaysTenure", "-XX:+NeverTenure"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, true /* neverTenure */, 7, 16)); runTenuringFlagsConsistencyTest( new String[]{"-XX:+NeverTenure", "-XX:+AlwaysTenure"}, false /* shouldFail */, new ExpectedTenuringFlags(true /* alwaysTenure */, false /* neverTenure */, 0, 0)); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:MaxTenuringThreshold=16", "-XX:+AlwaysTenure"}, false /* shouldFail */, new ExpectedTenuringFlags(true /* alwaysTenure */, false /* neverTenure */, 0, 0)); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:+AlwaysTenure", "-XX:MaxTenuringThreshold=16"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 7, 16)); runTenuringFlagsConsistencyTest( new String[]{"-XX:MaxTenuringThreshold=0", "-XX:+NeverTenure"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, true /* neverTenure */, 7, 16)); runTenuringFlagsConsistencyTest( new String[]{"-XX:+NeverTenure", "-XX:MaxTenuringThreshold=0"}, false /* shouldFail */, new ExpectedTenuringFlags(true /* alwaysTenure */, false /* neverTenure */, 0, 0)); // Illegal cases runTenuringFlagsConsistencyTest( ! new String[]{"-XX:MaxTenuringThreshold=17"}, true /* shouldFail */, new ExpectedTenuringFlags()); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:InitialTenuringThreshold=16"}, true /* shouldFail */, new ExpectedTenuringFlags()); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:InitialTenuringThreshold=17"}, true /* shouldFail */, new ExpectedTenuringFlags()); } private static void runTenuringFlagsConsistencyTest(String[] tenuringFlags, --- 102,151 ---- // "Last option wins" cases runTenuringFlagsConsistencyTest( new String[]{"-XX:+AlwaysTenure", "-XX:+NeverTenure"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, true /* neverTenure */, 7, 32)); runTenuringFlagsConsistencyTest( new String[]{"-XX:+NeverTenure", "-XX:+AlwaysTenure"}, false /* shouldFail */, new ExpectedTenuringFlags(true /* alwaysTenure */, false /* neverTenure */, 0, 0)); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:MaxTenuringThreshold=32", "-XX:+AlwaysTenure"}, false /* shouldFail */, new ExpectedTenuringFlags(true /* alwaysTenure */, false /* neverTenure */, 0, 0)); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:+AlwaysTenure", "-XX:MaxTenuringThreshold=32"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, false /* neverTenure */, 7, 32)); runTenuringFlagsConsistencyTest( new String[]{"-XX:MaxTenuringThreshold=0", "-XX:+NeverTenure"}, false /* shouldFail */, ! new ExpectedTenuringFlags(false /* alwaysTenure */, true /* neverTenure */, 7, 32)); runTenuringFlagsConsistencyTest( new String[]{"-XX:+NeverTenure", "-XX:MaxTenuringThreshold=0"}, false /* shouldFail */, new ExpectedTenuringFlags(true /* alwaysTenure */, false /* neverTenure */, 0, 0)); // Illegal cases runTenuringFlagsConsistencyTest( ! new String[]{"-XX:MaxTenuringThreshold=33"}, true /* shouldFail */, new ExpectedTenuringFlags()); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:InitialTenuringThreshold=32"}, true /* shouldFail */, new ExpectedTenuringFlags()); runTenuringFlagsConsistencyTest( ! new String[]{"-XX:InitialTenuringThreshold=33"}, true /* shouldFail */, new ExpectedTenuringFlags()); } private static void runTenuringFlagsConsistencyTest(String[] tenuringFlags,
< prev index next >