< prev index next >
test/compiler/tiered/TieredLevelsTest.java
Print this page
rev 8985 : 8059575: JEP-JDK-8043304: Test task: Tiered Compilation level transition tests
Reviewed-by: iveresov, thartmann, andrew
@@ -32,20 +32,18 @@
* TieredLevelsTest
* @summary Verify that all levels < 'TieredStopAtLevel' can be used
* @author igor.ignatyev@oracle.com
*/
public class TieredLevelsTest extends CompLevelsTest {
- public static void main(String[] args) throws Exception {
- if (!TIERED_COMPILATION) {
- System.err.println("Test isn't applicable w/ disabled "
- + "TieredCompilation. Skip test.");
+ public static void main(String[] args) throws Exception, Throwable {
+ if (CompilerWhiteBoxTest.skipOnTieredCompilation(false)) {
return;
}
CompilerWhiteBoxTest.main(TieredLevelsTest::new, args);
}
- private TieredLevelsTest(TestCase testCase) {
+ protected TieredLevelsTest(TestCase testCase) {
super(testCase);
// to prevent inlining of #method
WHITE_BOX.testSetDontInlineMethod(method, true);
}
@@ -74,16 +72,20 @@
testedTier <= COMP_LEVEL_MAX; ++testedTier) {
testUnavailableLevel(testedTier, bci);
}
}
-
@Override
protected void checkLevel(int expected, int actual) {
if (expected == COMP_LEVEL_FULL_PROFILE
&& actual == COMP_LEVEL_LIMITED_PROFILE) {
// for simple method full_profile may be replaced by limited_profile
+ if (IS_VERBOSE) {
+ System.out.printf("Level check: full profiling was replaced "
+ + "by limited profiling. Expected: %d, actual:%d",
+ expected, actual);
+ }
return;
}
super.checkLevel(expected, actual);
}
}
< prev index next >