Error: Cuda version 4.0 not available in this installation

Hi everyone, I have recently downloaded PGI Workstation 12.5 and the PGI Accelerator 12.5. I have used it to compile fortran programs and everything worked out fine, but when I wanted to try my first CUDA Fortran program it wouldn’t compile and gave me the following error message:

pgfortran-Error-CUDA version 4.0 is not available in this installation

I ran it with the command “$ pgfortran test1.cuf” , test1.cuf being the file containing the code.

I’m running all this on a 13’ MacBook Pro 2010, the GPU being a GeForce 320m.

running pgaccelinfo gives me the following information:


CUDA Driver Version: 4020

Device Number: 0
Device Name: GeForce 320M
Device Revision Number: 1.2

+a lot of (in my opinion) irrelevant technical stuff

I’ve also set the DYLD_LIBRARY_PATH variable to be /usr/local/cuda/bin, only upon doing that pgaccelinfo recognized my GPU.

I’m assuming that this is a configuration issue, since I have successfully compiled the sample programs given with the CUDA SDK using nvidias compiler.

One more thing that I’d like to mention is that pgaccelinfo displays my CUDA driver version as “CUDA Driver Version: 4020”, System preferences it is displayed as “CUDA Driver Version: 4.2.9” and nvidia’s deviceQuery programs displays it as “CUDA Driver Version / Runtime Version 4.2 / 4.2”
Is it possible that I’ve set the path wrong? Or some other reason why the versions differ?

Thanks in advance for your help on this issue,

Joe

Hi Joe,

pgfortran-Error-CUDA version 4.0 is not available in this installation

This typically means that the PGI supplied CUDA toolkit was not installed. When you installed 12.5, did you select yes when asked to install the CUDA Toolkit? If not, please re-install the compilers with the CUDA Toolkit.

Is it possible that I’ve set the path wrong? Or some other reason why the versions differ?

No this is all fine. The driver version is only relevant when you run your code. The above error is a compile time issue.

Hope this helps,
Mat

Hi Mat,

Thanks for your reply. I already tried reinstalling the compiler, because I read about it in a different thread. I didn’t see a prompt asking me whether I wanted to install the toolkit or not. I installed the PGI Workstation 12.5 package followed by the PGI Accelerator 12.5 package both times without prompts. And I’ve just checked again, there don’t seem to be any options other than the location of the install.

Also, I just realised there is a /opt/pgi/osx86/12.5/cuda folder, but no /opt/pgi/osx86-64/12.5/cuda folder. I don’t know if that could have anything to do with it?

Thanks again,

Joe

Hi Joe,

Also, I just realised there is a /opt/pgi/osx86/12.5/cuda folder, but no /opt/pgi/osx86-64/12.5/cuda folder. I don’t know if that could have anything to do with it?

The cuda folder should be in “/opt/pgi/osx86/2012/cuda” and “/opt/pgi/osx86-64/2012/cuda”. So what’s not expected is that the folder is under the 32-bit 12.5 directory.

We do install testing before each release but I’ll ask our engineers to double check that things are correct for MacOSX.

Thanks,
Mat

Hello Nvidia,
I am seeing this:

"One more thing that I’d like to mention is that pgaccelinfo displays my CUDA driver version as “CUDA Driver Version: 4020”, System preferences it is displayed as “CUDA Driver Version: 4.2.9” and nvidia’s deviceQuery programs displays it as “CUDA Driver Version / Runtime Version 4.2 / 4.2” and
“pgfortran-Error-CUDA version 11.1 is not available in this installation”
with cuda11.1.1 Was there ever a solution posted.

I am using the pgi 21.1 compilers and my compile line is

mpif90 -acc -ta=tesla:cc60,cc70,cuda11.1

Best regards,
Kyle

Hi Kyle,

For the driver version displayed by pgaccelinfo/nvaccelinfo, no this has not changed and it still displays the driver version as an integer which is returned by cudaDriverGetVersion. The deviceQuery program does additional modification on the returned integer before displaying.

In the original post, it doesn’t look like I took this as a complaint from the user so never reported it to engineering. Are you requesting that the Driver version be listed as “4.2” rather than “4020”? If so, how important would you consider this? I ask since this has been the same since we first started shipping pgaccelinfo back in the 2008 timeframe and it’s unclear if this would cause disruption for others.

For the second question, we did not include CUDA 11.1 as part of the NV HPC SDK and hence why you’re getting this error. I do see a typo in our HPC Compiler documentation which list 21.2 as shipping with 11.1, but that should be 11.2. Apologies if this caused confusion. 21.2 included CUDA 11.2 and 11.0 as shown in the Release Notes: Release Notes Version 21.2

In general the CUDA versions we plan to ship with each HPC SDK release is as follows:

  • current-major minus 1 (i.e. 10.2)
  • current-major . 0 (i.e. 11.0)
  • current-major.current-minor (i.e. 11.2 for now)

This is for a few reasons.

First, it aligns with the support model of other parts of the NVIDIA software stack and their CUDA support models, e.g. the DL frameworks.

Second, it allows users with current.major-1 drivers to use the HPC SDK, any users of current-major drivers (i.e. 11-series) to use the HPC SDK, and also provides the latest and greatest of CUDA to users that are able to upgrade their drivers to stay current.

-Mat