--- old/test/compiler/8009761/Test8009761.java 2014-06-25 13:35:35.290709454 +0200 +++ new/test/compiler/8009761/Test8009761.java 2014-06-25 13:35:35.214709457 +0200 @@ -40,6 +40,7 @@ public class Test8009761 { private static final WhiteBox WHITE_BOX = WhiteBox.getWhiteBox(); + private static int COMP_LEVEL_SIMPLE = 1; private static int COMP_LEVEL_FULL_OPTIMIZATION = 4; private static Method m3 = null; @@ -256,7 +257,11 @@ c1 = count; // Force the compilation of m3() that will inline m1() - WHITE_BOX.enqueueMethodForCompilation(m3, COMP_LEVEL_FULL_OPTIMIZATION); + if(!WHITE_BOX.enqueueMethodForCompilation(m3, COMP_LEVEL_FULL_OPTIMIZATION)) { + // C2 compiler not available, compile with C1 + WHITE_BOX.enqueueMethodForCompilation(m3, COMP_LEVEL_SIMPLE); + } + // Because background compilation is disabled, method should now be compiled if(!WHITE_BOX.isMethodCompiled(m3)) { throw new RuntimeException(m3 + " not compiled");