How to Compile CUDA App is Visual Studio 2010?

前端 未结 4 1258
情深已故
情深已故 2021-01-03 06:26

How to Compile CUDA App is Visual Studio 2010 ?

Here are my steps: 1. Create Empty C++ project without precompiled headers 2. Add main.cpp

int main()         


        
4条回答
  •  被撕碎了的回忆
    2021-01-03 07:24

    Yes i did, and it IS working.

    1. Create C++ project

    2. Project(right click)->build customisation Check "Cuda 3.2 compiler"*

    3. Add cudart.lib to properties->linker->input->additional dependencies

    4. Add main.cu -> properties Item type = CUDA C/C++*

    5. Project -> properties ->configuration Properties -> general -> v90 toolset**

    *) will appear after you install Nvidia Parallel Nsight. Be careful, you need special drivers for that, more on NSight homepage)

    **) you need to instal visual c++ 2008 express.

    Anyway, example project still should be available at my nvidia forum post. The problem i'm complaining there about is just out-of-date drivers.

提交回复
热议问题