-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Compiling Samples using NVidia HPC SDK Fails. Permission issue? #324
Comments
Hi Nick, I'm with the NVHPC Compiler team and was asked to step in and help. Though I just cloned the repo and didn't see any issue with building the package with the simple "cmake ../ ; make" commands using the nvcc that ships with the NVHPC SDK. Can you give any more details on any additional settings you gave to cmake or other relevant environment variables you've set? Also, do you have any examples of the errors you're seeing? Finally, which version of NVHPC do you have installed? Thanks, |
Hi Mat Thanks for picking this up hopefully this will be quickly solved. A bit of background. In earlier versions of CUDA and the HPC SDK I was able to install them separately. This meant that CUDA sat in the usr/local/ directories. Sadly not the case, well at least for me. I just re-downloaded the samples clean and followed the new process to compile the deviceQuery sample. This time all good so for the time being it looks as though my problem has gone away. I would if possible like some advice. In order to get things working I have flailed about in bashrc ending up with the following. --- Enable NVidia HPC ---
My gut feeling says this is a mess and probably largely unnecessary. Any advice as to clean this up would be great. Once again - many thanks for taking this on. Cheers Okay spoke too soon... Trying to compile nbody and bandwidthTest example and am getting.
Output from deviceQuery confirms capable GPU
Any ideas? N |
I can jump in here with a quick note that SM_100 is Blackwell, which is only supported from CUDA 12.8+. If you edit the |
Hi, System is Kubuntu 24.04 I’m thinking the HPC SDK has set up one CUDA in /opt/NVidia and the driver has set up another version wherever that lives. My problem is this. I want to use the HPC SDK to work on a hydrological model in Fortran. I want to use CUDA to improve performance in matrix calculations. Previously I would install CUDA in /usr/share/local and then install the HPC SDK on top and it would all work. Now HPC goes in /opt and carries its own version of CUDA which is not the current version. I’m not a proper programmer just an enthusiastic amateur, working on developing a course called “Cycles in the Biosphere”, largely self taught so to be honest all the Make, CMake stuff is sort of new to me. I’ve always had success working with CUDA in Windows using VS2022 it just works with a little tweaking. Previously CUDA / HPC worked just as seamlessly in Linux so I’m flumuxed now and feeling a little inadequate 😐 Unless there’s a simple solution I may just rebuild the machine and start from scratch using the latest CUDA and C/C++ or even Python. With grateful thanks for your input. |
This shouldn't matter. Since it would be huge package if we shipped all versions of CUDA with the NVHPC SDK, instead we ship the latest at the time of release (with 25.1 that was 12.6, but in 25.3 we'll move to 12.8). We have a separate package which also includes the last major release from the previous CUDA version (i.e. 11.8) and the base last major release (11.0). Within a major release, the driver and CUDA runtime are compatible so having a mismatch is ok. You just may not have access to newer features, such as Blackwell support in this case. It sounds like when they updated the samples, they did so with CUDA 12.8 in mind, so you just need to edit the Cmake config file, "CMakeList.txt", to remove the "100 101 120" from the "CMAKE_CUDA_ARCHITECTURES" list. As for your bashrc settings, these are fine. Yes you could clean it up a bit since you have repeated directories listed that are defined by marcos earlier, but there's nothing functionally wrong with it (at least not that I see). If you use modules at all, we do include module files which makes setting your environment easier. But if you don't, then it's probably more work to set up modules. It's really up to you on what makes the best sense. For the permission issue, I'm not sure. Presuming you installed the compilers, you should have permissions to those directories, so I'd need more info to help there. Also, "/opt/nvhpc" is just the default location. You can override where the base install directory is located. So if using /opt is a problem for you, rerun the "install.sh" script giving the new directory at the prompt. |
Thanks - I’ll work through your suggestions and fingers crossed! I’ll feedback when done. Cheers |
Hello,
Please could someone help.
I cannot compile the CUDA samples using the HPC toolkit. HPC has a different directory structure than the normal CUDA installation resulting in all sorts of errors when executing cmake ..
I need to use the HPC toolkit because I need to have the NVFORTRAN compiler. At the moment I’m feeling my way with CUDA and Linux so any guidance would be appreciated.
Many thanks
Thank You
Nick
The text was updated successfully, but these errors were encountered: