CUDA 11.0 VS2019 compile problem

Hello. I am new to the forum and new to CUDA.

I just installed VS 2019 Community and CUDA 11.0. I am running Windows 10. I’m having trouble compiling a simple hello world program and was hoping somebody could help me spot the problem.

I know that CUDA 11.0 is pretty new. Should I try downgrading to 10.2?


This is the error in the error list:
Error MSB3721
The command ““C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.0\bin\nvcc.exe” -gencode=arch=compute_52,code=“sm_52,compute_52” --use-local-env -ccbin “C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.26.28801\bin\HostX86\x64” -x cu -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.0\include” -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.0\include" -G --keep-dir x64\Debug -maxrregcount=0 --machine 64 --compile -cudart static -g -DWIN32 -DWIN64 -D_DEBUG -D_CONSOLE -D_MBCS -Xcompiler “/EHsc /W3 /nologo /Od /Fdx64\Debug\vc142.pdb /FS /Zi /RTC1 /MDd " -o x64\Debug\kernel.cu.obj “C:\Users\devver\source\repos\cuda_02\cuda_02\kernel.cu”” exited with code 1


Here is the error from the output:

“C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.0\bin\nvcc.exe” -gencode=arch=compute_52,code=“sm_52,compute_52” --use-local-env -ccbin “C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.26.28801\bin\HostX86\x64” -x cu -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.0\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.0\include" --keep-dir x64\Release -maxrregcount=0 --machine 64 --compile -cudart static -DWIN32 -DWIN64 -DNDEBUG -D_CONSOLE -D_MBCS -Xcompiler "/EHsc /W3 /nologo /O2 /Fdx64\Release\vc142.pdb /FS /Zi /MD " -o x64\Release\kernel.cu.obj “C:\Users\devver\source\repos\cuda_02\cuda_02\kernel.cu”
The system cannot find the path specified.


I don’t know which path it is unable to find. All of the paths in the command are valid, I have double-checked them:
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.0\bin
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v11.0\include
C:\Users\devver\source\repos\cuda_02\cuda_02\

Thanks