Upcoming GPU backend changes
Doug Simon
doug.simon at oracle.com
Thu Jan 30 08:15:36 PST 2014
I’ve now pushed the remaining changes for supporting for co-existing GPUs:
http://hg.openjdk.java.net/graal/graal/rev/49db2c1e3bee
The major change is the removal of CompilerToGPU and its associated C++ code. Instead, each GPU backend has only the native methods it needs and directly implements them in the C++ layer.
Also, all device initialization (linking device/simulator functions plus any device specific initialization) is *only* done in the constructors of PTXHotSpotBackend and HSAILHotSpotBackend. The Okra library is still correctly provisioned from okra-1.6-with-sim.jar if the latter is on the class path. Otherwise, Okra (still) relies on PATH and LD_LIBRARY_PATH being configured. To demonstrate this and to ensure the Sumatra prototype still works, I’ve created a webrev that includes Sumatra patch[1] directly in the Graal source code. This simplifies experimentation as one does not have to build a patched JDK:
http://cr.openjdk.java.net/~dnsimon/sumatra-on-graal/
The webrev includes a top level sumatra.sh script for running the demo.
I tested all this as much as I can but please let me know if it has broken anything.
-Doug
[1] http://cr.openjdk.java.net/~ecaspole/sumatrajdk.01/webrev/
On Jan 22, 2014, at 9:24 PM, Doug Simon <doug.simon at oracle.com> wrote:
> Hi,
>
> I’ve just created a JBS issue supporting multiple co-existing GPU backends: https://bugs.openjdk.java.net/browse/GRAAL-1
>
> Prior to making the C++ changes need for this, I want to bring the HSAIL Java code more in alignment with the recently revised PTX backend. Namely:
>
> 1. All compilation harness logic will be moved into HSAILHotSpotBackend (out of HSAILCompilationResult).
> 2. Create the equivalent of PTXWrapperBuilder for HSAIL. This is a generated stub that handles the transition from CPU to GPU and back. It also removes the need for the C++ HSAILKernelArguments class.
>
> If you have any questions or concerns about this, please let me know asap. I’m happy to have a Skype call as well if that is desirable.
>
> -Doug
>
>
More information about the graal-dev
mailing list