Using CUDA with Visual Studio 2017

后端 未结 8 1722
爱一瞬间的悲伤
爱一瞬间的悲伤 2020-11-28 21:53

I\'m trying to install CUDA, but I get a message saying \"No supported version of visual studio was found\". I think that this is because I am using Visual Studio 2017 (Comm

8条回答
  •  悲哀的现实
    2020-11-28 22:43

    For people seeing this latter.

    First, try to just install CUDA 10 (CUDA Toolkit 10.0).

    If it still doesn't work without any mods make sure that you have as many VC++ toolsets as you see on the list. Check out this video, stop at 8:41 and compare the lists.

    If for some reason you have to use CUDA 9.0 - 9.2 you will need to jump some hoops:

    • For cmd builds set vcvars_ver=14.11 - see this answer
    • For IDE builds set Platform Toolset (in project properties - General) to
      • Visual Studio 2017 (v141)) or
      • Visual Studio 2015 (v140))

    If you have very customized cmd based build, hunt #if _MSC_VER (in .../CUDA/.../include/crt/host_config.h) and remove trailing || _MSC_VER > ...

提交回复
热议问题