Mercurial > hg > graal-compiler
diff test/compiler/whitebox/MakeMethodNotCompilableTest.java @ 14909:4ca6dc0799b6
Backout jdk9 merge
author | Gilles Duboscq <duboscq@ssw.jku.at> |
---|---|
date | Tue, 01 Apr 2014 13:57:07 +0200 |
parents | f9a4b59ae350 |
children | 52b4284cb496 |
line wrap: on
line diff
--- a/test/compiler/whitebox/MakeMethodNotCompilableTest.java Tue Apr 01 14:09:03 2014 +0200 +++ b/test/compiler/whitebox/MakeMethodNotCompilableTest.java Tue Apr 01 13:57:07 2014 +0200 @@ -27,17 +27,26 @@ * @library /testlibrary /testlibrary/whitebox * @build MakeMethodNotCompilableTest * @run main ClassFileInstaller sun.hotspot.WhiteBox - * @run main/othervm/timeout=2400 -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -XX:CompileCommand=compileonly,SimpleTestCase$Helper::* MakeMethodNotCompilableTest + * @run main/othervm/timeout=2400 -Xbootclasspath/a:. -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI -XX:CompileCommand=compileonly,TestCase$Helper::* MakeMethodNotCompilableTest * @summary testing of WB::makeMethodNotCompilable() * @author igor.ignatyev@oracle.com */ public class MakeMethodNotCompilableTest extends CompilerWhiteBoxTest { private int bci; public static void main(String[] args) throws Exception { - CompilerWhiteBoxTest.main(MakeMethodNotCompilableTest::new, args); + if (args.length == 0) { + for (TestCase test : TestCase.values()) { + new MakeMethodNotCompilableTest(test).runTest(); + } + } else { + for (String name : args) { + new MakeMethodNotCompilableTest( + TestCase.valueOf(name)).runTest(); + } + } } - private MakeMethodNotCompilableTest(TestCase testCase) { + public MakeMethodNotCompilableTest(TestCase testCase) { super(testCase); // to prevent inlining of #method WHITE_BOX.testSetDontInlineMethod(method, true); @@ -53,7 +62,7 @@ */ @Override protected void test() throws Exception { - if (testCase.isOsr() && CompilerWhiteBoxTest.MODE.startsWith( + if (testCase.isOsr && CompilerWhiteBoxTest.MODE.startsWith( "compiled ")) { System.err.printf("Warning: %s is not applicable in %s%n", testCase.name(), CompilerWhiteBoxTest.MODE);