Mercurial > hg > truffle
comparison src/share/vm/graal/graalVMToCompiler.cpp @ 11606:4f69a5189e77
Create runtime object based on GPUIL type newly added to gpu class; some code refactoring.
author | bharadwaj |
---|---|
date | Wed, 11 Sep 2013 17:02:40 -0400 |
parents | 91e5f927af63 |
children | 03fe11f5f186 |
comparison
equal
deleted
inserted
replaced
11605:3676540f71cf | 11606:4f69a5189e77 |
---|---|
60 | 60 |
61 Handle VMToCompiler::graalRuntime() { | 61 Handle VMToCompiler::graalRuntime() { |
62 if (JNIHandles::resolve(_graalRuntimePermObject) == NULL) { | 62 if (JNIHandles::resolve(_graalRuntimePermObject) == NULL) { |
63 #ifdef AMD64 | 63 #ifdef AMD64 |
64 Symbol* name = NULL; | 64 Symbol* name = NULL; |
65 if (UseGPU && gpu::is_available() && gpu::has_gpu_linkage()) { | 65 if (UseGPU) { |
66 name = vmSymbols::com_oracle_graal_hotspot_ptx_PTXHotSpotGraalRuntime(); | 66 // Set name to PTXHotSpotRuntime if nVidia GPU was detected. |
67 if ((gpu::get_target_il_type() == gpu::PTX) && | |
68 gpu::is_available() && gpu::has_gpu_linkage()) { | |
69 name = vmSymbols::com_oracle_graal_hotspot_ptx_PTXHotSpotGraalRuntime(); | |
70 } | |
71 // Set name to corresponding runtime classname for other | |
72 // supported GPU runtimes, here. | |
67 } else { | 73 } else { |
68 name = vmSymbols::com_oracle_graal_hotspot_amd64_AMD64HotSpotGraalRuntime(); | 74 name = vmSymbols::com_oracle_graal_hotspot_amd64_AMD64HotSpotGraalRuntime(); |
69 } | 75 } |
70 #endif | 76 #endif |
71 #ifdef SPARC | 77 #ifdef SPARC |