Menu

guide to make new project in visual studio 2010 using cuda backend

vinha
2017-01-18
2017-01-20
  • vinha

    vinha - 2017-01-18

    hi,
    i had problem when create new project in visual studio 2010.
    After build successfully viennacl 1.7.1 by cmake, i open viennacl solution.
    Then i add new project for testing in solution.
    i copy all text from cuda-custom to new .cpp file in testing project.
    and incude all header of viennacl and cuda.
    my problem is that i can not build successfuly testing project. it is error "missing ,..".
    althought, cuda-custom example can run success. i try rename .cpp to .cu but i can not make .exe from testing project.
    i use cuda toolkit 8.0.
    can everyone help me for my problem?
    or give me guide to create new project and add .cu file or .cpp file to project in visual 2010 with windows 7 x64.

    thanks

     
  • Karl Rupp

    Karl Rupp - 2017-01-18

    Hi,
    you absolutely have to keep the .cu extension if you want to use the CUDA backend. Otherwise, the CUDA sources will not be processed correctly by NVCC.

    Other than that, the process for creating a CUDA-project is as usual. For example, have a look here:
    http://blog.cuvilib.com/2011/02/24/how-to-run-cuda-in-visual-studio-2010/
    Just make sure that you copy the viennacl/ sources into your project folder, or set the path to the sources correctly in the Visual Studio project settings.

    Best regards,
    Karli

     
  • vinha

    vinha - 2017-01-20

    Thank you so much.

    i use cuda 8.0 and boost 1.59 version.
    After build with cmake i run Blas3-cuda example.
    but it show me error: "iterrator is not a member .. in vector.hpp"
    Can you tell me aboit this error?
    I dont know this error is made by incompatible version bettween cuda and boost or other reason?

     

Log in to post a comment.