2

My lab just received a Tesla C2070 , and the card is installed on a machine running windows server 64 bits. I'm supposed to write some cuda simulations. Do I need to install the 64 bits version of the SDK and CUDA toolkits ? The reason I'm asking is because I'd like to use Visual c++ express to compile and they seem to be really really 32 bit oriented. Or is there another compiler which would altogether free me from that restriction ?

Thanks.

Edit 1 Thanks for the answers. So far I can compile 32 bits cuda / openCL code. After installing the SDK, changing the target to 64 and linking against 64b lib, well it still won't work.

C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\BuildCustomizations\CUDA 4.2.targets(361,9): error MSB3721: The command ""C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v4.2\bin\nvcc.exe" -gencode=arch=compute_10,code=\"sm_10,compute_10\" --use-local-env --cl-version  -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\x86_amd64"  -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v4.2\include"  -G  --keep-dir "x64\Debug" -maxrregcount=0  --machine 64 --compile  -g    -Xcompiler "/EHsc /nologo /Od /Zi  /MDd  " -o "x64\Debug\test.cu.obj" "c:\Users\A\Documents\Visual Studio 2010\Projects\cudaTest2\cudaTest2\test.cu"" exited with code -1.

Finally, is there a point to compile to a 64bit app when speaking about gpgpu simulation ? What I mean is that the code running on the host is nearly nothing, and the code running on the gpu well it's compiled by nvcc so doesn't really matter what I chose, 32 or 64... Am I wrong (probably) ?

zebullon
  • 191
  • 3
  • 10

2 Answers2

2

This isn't what you asked, but...

Visual C++ Express will compile 64-bit programs just fine. It so happens that Express is not distributed with the 64-bit compiler, but the compiler is a separate download.

Install the Microsoft Windows SDK 7.1 and you will be able to compile for x64 with Microsoft Visual C++ Express.

Dietrich Epp
  • 205,541
  • 37
  • 345
  • 415
2

You should download the 64bit SDK for 64Bit OS,In that there are libraries for both the version 32Bit and 64Bit.For visual C++ 32Bit application you should use 32Bit libraries and it will work.

For example in my case: I have 64Bit Windows7 OS,for this I have used 64Bit CUDA SDK and for developing my 32bit c++ application in visual studio 2008 I have used 32Bit libraries of cuda exported with the SDK.

ATG
  • 732
  • 3
  • 11
  • 21
  • 1
    This one works, at least my OpenCL simulation runs just fine if I link against the 32 bit library. – zebullon Sep 04 '12 at 03:41