Mercurial > hg > graal-jvmci-8
comparison src/share/vm/graal/graalVMToCompiler.cpp @ 9913:35f93560b1f0
ensure that <clinit> for HotSpotOptions is called irrespective of whether and -G: options are specified
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Thu, 06 Jun 2013 17:27:07 +0200 |
parents | 2dc020b33a6e |
children | 0f7ca53be929 |
comparison
equal
deleted
inserted
replaced
9912:fbad7372eccd | 9913:35f93560b1f0 |
---|---|
71 JavaCalls::call_virtual(&result, compilerKlass, vmSymbols::getVMToCompiler_name(), vmSymbols::getVMToCompiler_signature(), &args, Thread::current()); | 71 JavaCalls::call_virtual(&result, compilerKlass, vmSymbols::getVMToCompiler_name(), vmSymbols::getVMToCompiler_signature(), &args, Thread::current()); |
72 check_pending_exception("Couldn't get VMToCompiler"); | 72 check_pending_exception("Couldn't get VMToCompiler"); |
73 _vmToCompilerPermObject = JNIHandles::make_global((oop) result.get_jobject()); | 73 _vmToCompilerPermObject = JNIHandles::make_global((oop) result.get_jobject()); |
74 } | 74 } |
75 return Handle(JNIHandles::resolve_non_null(_vmToCompilerPermObject)); | 75 return Handle(JNIHandles::resolve_non_null(_vmToCompilerPermObject)); |
76 } | |
77 | |
78 void VMToCompiler::initOptions() { | |
79 KlassHandle compilerKlass = loadClass(vmSymbols::com_oracle_graal_hotspot_HotSpotOptions()); | |
80 Thread* THREAD = Thread::current(); | |
81 compilerKlass->initialize(THREAD); | |
82 check_pending_exception("Error while calling initOptions"); | |
76 } | 83 } |
77 | 84 |
78 jboolean VMToCompiler::setOption(Handle option) { | 85 jboolean VMToCompiler::setOption(Handle option) { |
79 assert(!option.is_null(), ""); | 86 assert(!option.is_null(), ""); |
80 KlassHandle compilerKlass = loadClass(vmSymbols::com_oracle_graal_hotspot_HotSpotOptions()); | 87 KlassHandle compilerKlass = loadClass(vmSymbols::com_oracle_graal_hotspot_HotSpotOptions()); |