Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation failure of tornado-drivers-ptx #274

Open
PolyRocketMatt opened this issue Oct 1, 2023 · 8 comments
Open

Compilation failure of tornado-drivers-ptx #274

PolyRocketMatt opened this issue Oct 1, 2023 · 8 comments
Assignees
Labels
graal-update Update the Graal JIT compiler windows

Comments

@PolyRocketMatt
Copy link

PolyRocketMatt commented Oct 1, 2023

Describe the bug

When executing steps to install TornadoVM on Windows from here, I get a compilation error from one of the TornadoVM modules.

How To Reproduce

    1. Follow instructions 1 through 5 from here (I did look at the known issues and started with a fresh MSYS2 installation).
    1. When compiling using the mingw64 terminal with the following command:
      source etc/sources.env make graal-jdk-17-plus BACKEND=ptx
      A compilation error arises (see this gist for the stack trace/log output)

Expected behavior

Successfull build of TornadoVM (step 6 in the instructions)

Computing system setup (please complete the following information):

  • OS: [Windows 10]
  • PTX: cuda_11.7.r11.7/compiler.31294372_0
  • Nvidia Driver: 31.0.15.3114
  • TornadoVM Commit ID: 9158641
  • JDK: 17
  • Maven: 3.9.4

Additional context

The full log output of the build can be found here.


@stratika
Copy link
Collaborator

stratika commented Oct 1, 2023

hi @PolyRocketMatt, can you please also provide the JDK version that you downloaded for your JAVA_HOME?

@PolyRocketMatt
Copy link
Author

Updated the original post with that information, as well as the version of Maven I am using.

@stratika
Copy link
Collaborator

stratika commented Oct 1, 2023

The JDK17 binary breaks in Windows. My guess is that the link pointing to the JDK17 is not compatible with the latest Graal 23.1.0 compiler update that we performed recently. We will validate it, and report any updates here. In the mean time, the JDK21 binary seems to be working.

@stratika stratika added graal-update Update the Graal JIT compiler windows labels Oct 1, 2023
@jjfumero
Copy link
Member

jjfumero commented Oct 1, 2023

There is no Graal 23.1.0 for JDK 17, only for JDK 21. We will update the docs.

@jjfumero
Copy link
Member

jjfumero commented Oct 2, 2023

I just double-checked on Windows 11 and MSys64. It works for JDK 21 and GraalVM.

Just for reference, here's my source file:

#!/bin/bash
export JAVA_HOME="C:\Users\jjfum\Documents\bin\jvms\graalvm-jdk-21_windows-x64_bin\graalvm-jdk-21+35.1"

## NEXT TWO LINES NECESSARY TO BUILD PTX (NVIDIA CUDA) BACKEND
## COMMENT THEM OUT OR JUST IGNORE IF YOU ARE NOT INTERESTED IN PTX BUILD
## OTHERWISE UPDATE 'CUDA_PATH' WITH ACTUAL VALUE (REMEMBER OF UNIX_STYLE SLASHES AND SPACES!!!)
export CUDA_PATH="C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.1"
export PTX_LDFLAGS=-L\"$CUDA_PATH/lib/x64\"

# LEAVE THE REST OF FILE 'AS IS'
# DON'T ALTER!
export PATH=$PWD/bin/bin:$PATH               ## This directory will be automatically generated during Tornado compilation
export TORNADO_SDK=$PWD/bin/sdk              ## This directory will be automatically generated during Tornado compilation
CMAKE_FILE=$(where cmake | head -n 1)
export CMAKE_ROOT=${CMAKE_FILE%\\*\\*}

Then:

source sources.sh
make graal-jdk-17-plus BACKEND=ptx

You can also build with the OpenCL backend.

@jjfumero
Copy link
Member

jjfumero commented Oct 4, 2023

@PolyRocketMatt , did you get the chance to test it again? Did this solve the issue?

@PolyRocketMatt
Copy link
Author

I did. Building now seems to work, but even with a fresh install and all it seems like the tornado command is not recognized (even though building everything seemed to be succesful).

@jjfumero
Copy link
Member

Hi @PolyRocketMatt . sorry I missed the last message. Did it finally work?
If it builds, then the issue could be the PATH to the TornadoVM bin folder ($TORNADO_ROOT/bin/sdk/bin)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
graal-update Update the Graal JIT compiler windows
Projects
None yet
Development

No branches or pull requests

4 participants