comparison test/compiler/whitebox/CompilerWhiteBoxTest.java @ 14661:bbfe3ac1471d

8007270: Make IsMethodCompilable test work with tiered Summary: Only c2 compiles counts toward cutoff Reviewed-by: kvn, roland
author neliasso
date Tue, 28 Jan 2014 15:05:46 +0100
parents f9a4b59ae350
children 2dfa56e10640
comparison
equal deleted inserted replaced
14660:3c6ae9109a86 14661:bbfe3ac1471d
194 System.out.println("at test's end:"); 194 System.out.println("at test's end:");
195 printInfo(); 195 printInfo();
196 } 196 }
197 197
198 /** 198 /**
199 * Checks, that {@linkplain #method} is not compiled at the given compilation
200 * level or above.
201 *
202 * @param compLevel
203 *
204 * @throws RuntimeException if {@linkplain #method} is in compiler queue or
205 * is compiled, or if {@linkplain #method} has zero
206 * compilation level.
207 */
208
209 protected final void checkNotCompiled(int compLevel) {
210 if (WHITE_BOX.isMethodQueuedForCompilation(method)) {
211 throw new RuntimeException(method + " must not be in queue");
212 }
213 if (WHITE_BOX.getMethodCompilationLevel(method, false) >= compLevel) {
214 throw new RuntimeException(method + " comp_level must be >= maxCompLevel");
215 }
216 if (WHITE_BOX.getMethodCompilationLevel(method, true) >= compLevel) {
217 throw new RuntimeException(method + " osr_comp_level must be >= maxCompLevel");
218 }
219 }
220
221 /**
199 * Checks, that {@linkplain #method} is not compiled. 222 * Checks, that {@linkplain #method} is not compiled.
200 * 223 *
201 * @throws RuntimeException if {@linkplain #method} is in compiler queue or 224 * @throws RuntimeException if {@linkplain #method} is in compiler queue or
202 * is compiled, or if {@linkplain #method} has zero 225 * is compiled, or if {@linkplain #method} has zero
203 * compilation level. 226 * compilation level.