# Somehow I got a error when I tried to run the CUDA 11.1 samples on MS Visual Studio 2019

**URL:** <https://forums.developer.nvidia.com/t/somehow-i-got-a-error-when-i-tried-to-run-the-cuda-11-1-samples-on-ms-visual-studio-2019/160632>\
**Category:** CUDA Setup and Installation\
**Tags:** visual-studio, cuda\
**Created:** [November 28, 2020, 12:49pm UTC](https://forums.developer.nvidia.com/t/somehow-i-got-a-error-when-i-tried-to-run-the-cuda-11-1-samples-on-ms-visual-studio-2019/160632 "2020-11-28T12:49:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Halloweens](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@Halloweens](https://forums.developer.nvidia.com/u/Halloweens)\
**Post date:** [November 28, 2020, 12:49pm UTC](https://forums.developer.nvidia.com/t/somehow-i-got-a-error-when-i-tried-to-run-the-cuda-11-1-samples-on-ms-visual-studio-2019/160632/1 "2020-11-28T12:49:26Z")

</div>

I followed the steps of some sort of tutorial articles on the internet, installed vs 2019 and cuda 11.1, then I tried to run the samples, somehow I got a error:

D:\Visual Studio 2019\MSBuild\Microsoft\VC\v160\BuildCustomizations\CUDA 11.1.targets(785,9): error MSB3721: command ““D:\CUDA development\bin\nvcc.exe” -gencode=arch=compute\_35,code="sm\_35,compute\_35" -gencode=arch=compute\_37,code="sm\_37,compute\_37" -gencode=arch=compute\_50,code="sm\_50,compute\_50" -gencode=arch=compute\_52,code="sm\_52,compute\_52" -gencode=arch=compute\_60,code="sm\_60,compute\_60" -gencode=arch=compute\_61,code="sm\_61,compute\_61" -gencode=arch=compute\_70,code="sm\_70,compute\_70" -gencode=arch=compute\_75,code="sm\_75,compute\_75" -gencode=arch=compute\_80,code="sm\_80,compute\_80" -gencode=arch=compute\_86,code="sm\_86,compute\_86" --use-local-env -ccbin “D:\Visual Studio 2019\VC\Tools\MSVC\14.28.29333\bin\HostX86\x64” -x cu -I./ -I…/…/common/inc -I./ -I"D:\CUDA development/include" -I…/…/common/inc -I"D:\CUDA development\include" -G --keep-dir x64\Debug -maxrregcount=0 --machine 64 --compile -cudart static -Xcompiler “/wd 4819” -g -DWIN32 -DWIN32 -D\_MBCS -D\_MBCS -Xcompiler "/EHsc /W3 /nologo /Od /Fdx64/Debug/vc142.pdb /FS /Zi /RTC1 /MTd " -o x64/Debug/asyncAPI.cu.obj “D:\CUDA samples\0\_Simple\asyncAPI\asyncAPI.cu”” has exited, return code 1。

went to search a lot, just can’t find a way to solve it, :(

---

<div class="post-metadata">

**Author:** ![w.tangsuksant.m](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@w.tangsuksant.m](https://forums.developer.nvidia.com/u/w.tangsuksant.m)\
**Post date:** [November 28, 2020, 4:41pm UTC](https://forums.developer.nvidia.com/t/somehow-i-got-a-error-when-i-tried-to-run-the-cuda-11-1-samples-on-ms-visual-studio-2019/160632/2 "2020-11-28T16:41:02Z")

</div>

Me too!  
it shows the same problem
