< prev index next >
test/hotspot/jtreg/compiler/valhalla/valuetypes/ValueTypeTest.java
Print this page
*** 749,754 ****
--- 749,767 ----
if (VERBOSE) {
System.out.println("enqueueMethodForCompilation " + m + ", level = " + level);
}
WHITE_BOX.enqueueMethodForCompilation(m, level);
}
+
+ // Unlike C2, C1 intrinsics never deoptimize System.arraycopy. Instead, we fall back to
+ // a normal method invocation when encountering flattened arrays.
+ static boolean isCompiledByC2(Method m) {
+ int CompLevel_none = 0, // Interpreter
+ CompLevel_simple = 1, // C1
+ CompLevel_limited_profile = 2, // C1, invocation & backedge counters
+ CompLevel_full_profile = 3, // C1, invocation & backedge counters + mdo
+ CompLevel_full_optimization = 4; // C2 or JVMCI
+
+ return USE_COMPILER && !XCOMP && WHITE_BOX.isMethodCompiled(m, false) &&
+ WHITE_BOX.getMethodCompilationLevel(m, false) >= CompLevel_full_optimization;
+ }
}
< prev index next >