comparison jvmci/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotJVMCIRuntime.java @ 23394:7743f81f8c4a

clean up and minimize JVMCI (JDK-8156835) - part 2
author Doug Simon <doug.simon@oracle.com>
date Fri, 13 May 2016 10:44:29 +0200
parents 1d4ce2d19e52
children b5557b757040
comparison
equal deleted inserted replaced
23393:1d4ce2d19e52 23394:7743f81f8c4a
341 341
342 /** 342 /**
343 * Called from the VM. 343 * Called from the VM.
344 */ 344 */
345 @SuppressWarnings({"unused"}) 345 @SuppressWarnings({"unused"})
346 private CompilationRequestResult compileMethod(HotSpotResolvedJavaMethod method, int entryBCI, long jvmciEnv, int id) { 346 private HotSpotCompilationRequestResult compileMethod(HotSpotResolvedJavaMethod method, int entryBCI, long jvmciEnv, int id) {
347 CompilationRequestResult result = getCompiler().compileMethod(new HotSpotCompilationRequest(method, entryBCI, jvmciEnv, id)); 347 CompilationRequestResult result = getCompiler().compileMethod(new HotSpotCompilationRequest(method, entryBCI, jvmciEnv, id));
348 assert result != null : "compileMethod must always return something"; 348 assert result != null : "compileMethod must always return something";
349 return result; 349 HotSpotCompilationRequestResult hsResult;
350 if (result instanceof HotSpotCompilationRequestResult) {
351 hsResult = (HotSpotCompilationRequestResult) result;
352 } else {
353 Object failure = result.getFailure();
354 if (failure != null) {
355 boolean retry = false; // Be conservative with unknown compiler
356 hsResult = HotSpotCompilationRequestResult.failure(failure.toString(), retry);
357 } else {
358 int inlinedBytecodes = -1;
359 hsResult = HotSpotCompilationRequestResult.success(inlinedBytecodes);
360 }
361 }
362
363 return hsResult;
350 } 364 }
351 365
352 /** 366 /**
353 * Shuts down the runtime. 367 * Shuts down the runtime.
354 * 368 *