< prev index next >

test/hotspot/jtreg/compiler/valhalla/valuetypes/TestNewAcmp.java

Print this page
rev 55127 : 8223351: [lworld] Primary mirror and nullable mirror for inline type
Reviewed-by: tbd

*** 36,49 **** import jdk.test.lib.Asserts; import jdk.test.lib.process.ProcessTools; import jdk.test.lib.process.OutputAnalyzer; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; - import java.lang.invoke.*; import java.lang.reflect.Method; - import java.util.regex.Pattern; - import java.util.regex.Matcher; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import sun.hotspot.WhiteBox; --- 36,46 ----
*** 1401,1411 **** int end = (nullMode != 2) ? args.length : 1; for (int i = start; i < end; ++i) { if (args[i] != null && !parameterTypes[0].isInstance(args[i])) { continue; } ! if (args[i] == null && parameterTypes[0] == MyValue1.class.asValueType()) { continue; } if (parameterCount == 1) { // Null checks System.out.print("Testing " + m.getName() + "(" + args[i] + ")"); --- 1398,1408 ---- int end = (nullMode != 2) ? args.length : 1; for (int i = start; i < end; ++i) { if (args[i] != null && !parameterTypes[0].isInstance(args[i])) { continue; } ! if (args[i] == null && parameterTypes[0] == MyValue1.class.asPrimaryType()) { continue; } if (parameterCount == 1) { // Null checks System.out.print("Testing " + m.getName() + "(" + args[i] + ")");
*** 1423,1433 **** // Equality checks for (int j = 0; j < args.length; ++j) { if (args[j] != null && !parameterTypes[1].isInstance(args[j])) { continue; } ! if (args[j] == null && parameterTypes[1] == MyValue1.class.asValueType()) { continue; } System.out.print("Testing " + m.getName() + "(" + args[i] + ", " + args[j] + ")"); // Avoid acmp in the computation of the expected result! boolean equal = equalities[i][j]; --- 1420,1430 ---- // Equality checks for (int j = 0; j < args.length; ++j) { if (args[j] != null && !parameterTypes[1].isInstance(args[j])) { continue; } ! if (args[j] == null && parameterTypes[1] == MyValue1.class.asPrimaryType()) { continue; } System.out.print("Testing " + m.getName() + "(" + args[i] + ", " + args[j] + ")"); // Avoid acmp in the computation of the expected result! boolean equal = equalities[i][j];
*** 1511,1528 **** int idx = i % args.length; compiled = WHITE_BOX.isMethodCompiled(cmpSometimesEqual1_m, false); res = cmpSometimesEqual1(args[idx]); if (ACmpOnValues != 3) { ! Asserts.assertEQ(res, args[idx] == null || !args[idx].getClass().isValue()); } else if (compiled) { Asserts.assertTrue(res); } compiled = WHITE_BOX.isMethodCompiled(cmpSometimesEqual2_m, false); res = cmpSometimesEqual2(args[idx]); if (ACmpOnValues != 3) { ! Asserts.assertNE(res, args[idx] == null || !args[idx].getClass().isValue()); } else if (compiled) { Asserts.assertFalse(res); } } } --- 1508,1525 ---- int idx = i % args.length; compiled = WHITE_BOX.isMethodCompiled(cmpSometimesEqual1_m, false); res = cmpSometimesEqual1(args[idx]); if (ACmpOnValues != 3) { ! Asserts.assertEQ(res, args[idx] == null || !args[idx].getClass().isInlineClass()); } else if (compiled) { Asserts.assertTrue(res); } compiled = WHITE_BOX.isMethodCompiled(cmpSometimesEqual2_m, false); res = cmpSometimesEqual2(args[idx]); if (ACmpOnValues != 3) { ! Asserts.assertNE(res, args[idx] == null || !args[idx].getClass().isInlineClass()); } else if (compiled) { Asserts.assertFalse(res); } } }
< prev index next >