Mercurial > hg > truffle
comparison src/share/vm/graal/graalVMToCompiler.cpp @ 5526:87e4aed94b26
Remove HotSpotCompiler interface, let HotSpotCompilerImpl implement GraalRuntime (in preparation of renaming).
author | Thomas Wuerthinger <thomas.wuerthinger@oracle.com> |
---|---|
date | Fri, 08 Jun 2012 18:31:33 +0200 |
parents | 35753b8c098a |
children | 82f2bb47c97e |
comparison
equal
deleted
inserted
replaced
5525:77d302416830 | 5526:87e4aed94b26 |
---|---|
51 return Handle(JNIHandles::resolve_non_null(_compilerPermObject)); | 51 return Handle(JNIHandles::resolve_non_null(_compilerPermObject)); |
52 } | 52 } |
53 | 53 |
54 Handle VMToCompiler::instance() { | 54 Handle VMToCompiler::instance() { |
55 if (JNIHandles::resolve(_vmToCompilerPermObject) == NULL) { | 55 if (JNIHandles::resolve(_vmToCompilerPermObject) == NULL) { |
56 KlassHandle compilerKlass = SystemDictionary::resolve_or_null(vmSymbols::com_oracle_graal_hotspot_Compiler(), SystemDictionary::java_system_loader(), NULL, Thread::current()); | 56 KlassHandle compilerKlass = SystemDictionary::resolve_or_null(vmSymbols::com_oracle_graal_hotspot_CompilerImpl(), SystemDictionary::java_system_loader(), NULL, Thread::current()); |
57 check_not_null(compilerKlass(), "Couldn't find class com.sun.hotspot.graal.Compiler"); | 57 check_not_null(compilerKlass(), "Couldn't find class com.sun.hotspot.graal.Compiler"); |
58 | 58 |
59 JavaValue result(T_OBJECT); | 59 JavaValue result(T_OBJECT); |
60 JavaCallArguments args; | 60 JavaCallArguments args; |
61 args.set_receiver(compilerInstance()); | 61 args.set_receiver(compilerInstance()); |
62 JavaCalls::call_interface(&result, compilerKlass, vmSymbols::getVMToCompiler_name(), vmSymbols::getVMToCompiler_signature(), &args, Thread::current()); | 62 JavaCalls::call_virtual(&result, compilerKlass, vmSymbols::getVMToCompiler_name(), vmSymbols::getVMToCompiler_signature(), &args, Thread::current()); |
63 check_pending_exception("Couldn't get VMToCompiler"); | 63 check_pending_exception("Couldn't get VMToCompiler"); |
64 _vmToCompilerPermObject = JNIHandles::make_global((oop) result.get_jobject()); | 64 _vmToCompilerPermObject = JNIHandles::make_global((oop) result.get_jobject()); |
65 } | 65 } |
66 return Handle(JNIHandles::resolve_non_null(_vmToCompilerPermObject)); | 66 return Handle(JNIHandles::resolve_non_null(_vmToCompilerPermObject)); |
67 } | 67 } |