Integrating CUDA with Visual Studio 2008
Hi.

I'm quite new to CUDA, and I want to integrate the nvcc compiler with Visual Studio 2008. I took a look at this: [url="http://sarathc.wordpress.com/2008/09/26/how-to-integrate-cuda-with-visual-c/"]http://sarathc.wordpress.com/2008/09/26/ho...-with-visual-c/[/url]

But it says CUDA doesn't support Visual Studio 2008. Is there a way to make CUDA work under Visual Studio 2008? Or another way to make a CUDA dll then through Visual Studio? (I'm not familiar with Visual Studio either :"> )
Hi.



I'm quite new to CUDA, and I want to integrate the nvcc compiler with Visual Studio 2008. I took a look at this: http://sarathc.wordpress.com/2008/09/26/ho...-with-visual-c/



But it says CUDA doesn't support Visual Studio 2008. Is there a way to make CUDA work under Visual Studio 2008? Or another way to make a CUDA dll then through Visual Studio? (I'm not familiar with Visual Studio either :"> )

#1
Posted 06/18/2009 01:23 PM   
CUDA now does support VS 2008, that's an old article.
CUDA now does support VS 2008, that's an old article.

#2
Posted 06/18/2009 06:50 PM   
full support of VS2008 in CUDA 2.2 :) just download everything and you are set
full support of VS2008 in CUDA 2.2 :) just download everything and you are set

#3
Posted 06/18/2009 07:59 PM   
Great, but how can I make nvcc my compiler for .cu files? I'm brand new with Visual Studio you see, I usually program in Linux, but at my job I have to use Visual Studio, so I really don't know how to do things there. Any help is appreciated. I tried doing what stands in the link, but no luck :(
Great, but how can I make nvcc my compiler for .cu files? I'm brand new with Visual Studio you see, I usually program in Linux, but at my job I have to use Visual Studio, so I really don't know how to do things there. Any help is appreciated. I tried doing what stands in the link, but no luck :(

#4
Posted 06/19/2009 06:42 AM   
Easisest way would be to use the CUDA VS Wizard [url="http://sourceforge.net/projects/cudavswizard"]http://sourceforge.net/projects/cudavswizard[/url]
It will create a project with a sample cu file that will be configured for compilation with nvcc.
Then you simply click the build button in VS 2008.
Easisest way would be to use the CUDA VS Wizard http://sourceforge.net/projects/cudavswizard

It will create a project with a sample cu file that will be configured for compilation with nvcc.

Then you simply click the build button in VS 2008.

#5
Posted 06/19/2009 10:43 AM   
[quote name='martiert' post='554527' date='Jun 19 2009, 11:12 AM']Great, but how can I make nvcc my compiler for .cu files? I'm brand new with Visual Studio you see, I usually program in Linux, but at my job I have to use Visual Studio, so I really don't know how to do things there. Any help is appreciated. I tried doing what stands in the link, but no luck :([/quote]

After installing CUDA SDK check this file for Quick Start Instructions :


\NVIDIA CUDA SDK\doc\CUDA_SDK_release_notes_windows.txt

in this file check "II. Creating Your Own CUDA Program",

By following the instructions, you can create your own project with template of CUDA SDK in you CUDA SDK directory/projects/yourprojectname.


CUDA SDK samples use some library and header files in CUDA SDK directory for example cutil.h . so if you want to change the location of your project you have to add this library and header file.

This links help you how to change command line options for custom command line in visual studio for cuda samples.
Check these link:

[url="http://sarathc.wordpress.com/2008/09/26/how-to-integrate-cuda-with-visual-c/"]http://sarathc.wordpress.com/2008/09/26/ho...-with-visual-c/[/url]

[url="http://llpanorama.wordpress.com/2008/05/21/my-first-cuda-program/"]http://llpanorama.wordpress.com/2008/05/21...t-cuda-program/[/url]
[quote name='martiert' post='554527' date='Jun 19 2009, 11:12 AM']Great, but how can I make nvcc my compiler for .cu files? I'm brand new with Visual Studio you see, I usually program in Linux, but at my job I have to use Visual Studio, so I really don't know how to do things there. Any help is appreciated. I tried doing what stands in the link, but no luck :(



After installing CUDA SDK check this file for Quick Start Instructions :





\NVIDIA CUDA SDK\doc\CUDA_SDK_release_notes_windows.txt



in this file check "II. Creating Your Own CUDA Program",



By following the instructions, you can create your own project with template of CUDA SDK in you CUDA SDK directory/projects/yourprojectname.





CUDA SDK samples use some library and header files in CUDA SDK directory for example cutil.h . so if you want to change the location of your project you have to add this library and header file.



This links help you how to change command line options for custom command line in visual studio for cuda samples.

Check these link:



http://sarathc.wordpress.com/2008/09/26/ho...-with-visual-c/



http://llpanorama.wordpress.com/2008/05/21...t-cuda-program/

#6
Posted 06/19/2009 10:47 AM   
[quote name='martiert' date='18 June 2009 - 10:23 PM' timestamp='1245331409' post='554136']
Hi.

I'm quite new to CUDA, and I want to integrate the nvcc compiler with Visual Studio 2008. I took a look at this: [url="http://sarathc.wordpress.com/2008/09/26/how-to-integrate-cuda-with-visual-c/"]http://sarathc.wordpress.com/2008/09/26/ho...-with-visual-c/[/url]

But it says CUDA doesn't support Visual Studio 2008. Is there a way to make CUDA work under Visual Studio 2008? Or another way to make a CUDA dll then through Visual Studio? (I'm not familiar with Visual Studio either :"> )
[/quote]


Seems some years have passed since you asked this, but well, I hope this could be useful for some people in the future since google bring me to this topic when i was trying to do this:

http://digitalerr0r.wordpress.com/2010/12/19/parallel-computing-using-the-gpu-tutorial-3-integrate-cuda-3-2-into-visual-studio-2008/

this tutorial is just perfect and it works nice.
[quote name='martiert' date='18 June 2009 - 10:23 PM' timestamp='1245331409' post='554136']

Hi.



I'm quite new to CUDA, and I want to integrate the nvcc compiler with Visual Studio 2008. I took a look at this: http://sarathc.wordpress.com/2008/09/26/ho...-with-visual-c/



But it says CUDA doesn't support Visual Studio 2008. Is there a way to make CUDA work under Visual Studio 2008? Or another way to make a CUDA dll then through Visual Studio? (I'm not familiar with Visual Studio either :"> )







Seems some years have passed since you asked this, but well, I hope this could be useful for some people in the future since google bring me to this topic when i was trying to do this:



http://digitalerr0r.wordpress.com/2010/12/19/parallel-computing-using-the-gpu-tutorial-3-integrate-cuda-3-2-into-visual-studio-2008/



this tutorial is just perfect and it works nice.

#7
Posted 10/14/2011 11:30 AM   
Scroll To Top