Hi All,
I am trying to simply compile and execute Szeta.cu from the CUDA Matlab Toolkit on the following system:
Windows XP x64
Matlab 2007a, 2007b, and 2008a
CUDA 2.0
CUDA Matlab Toolkit
VS 2005 Professional
Dual Quad-Core Xeons @ 2.33 GHz
10 GB of RAM
nVidia GeForce 8800 GTX 786 MB
I would like to be able to use Matlab 2008a, but I gather from a previous post that some files have changed from the 2007 versions and the current CUDA Matlab Toolkit may not work. Consequently I have installed 2007a and 2007b in an attempt to make CUDA work with Matlab to no avail.
In all three versions of Matlab I can compile and execute the following lines from the README.txt successfully:
[font=“Courier”]>> mex fft2_cuda.c -IC:\CUDA\include -LC:\CUDA\lib -lcudart -lcufft
mex fft2_cuda_sp_dp.c -IC:\CUDA\include -LC:\CUDA\lib -lcudart -lcufft
mex ifft2_cuda.c -IC:\CUDA\include -LC:\CUDA\lib -lcudart -lcufft
speed_fft
tic; FS_2Dturb(128,1,1,1); toc;[/font]
However, the following line fails (although slighly differently) in all three versions of Matlab after updating nvmexopts.bat to work with x64:
[font=“Courier”]>> nvmex -f nvmexopts.bat Szeta.cu -IC:\cuda\include -LC:\cuda\lib -lcufft -lcudart[/font]
In Matlab 2008a:
[font=“Courier”]Undefined subroutine &main::uuidgen called at C:\Program Files\MATLAB\R2008a\bin\nvmex.pl line 728.
??? Error using ==> nvmex at 206
Unable to complete successfully.[/font]
In Matlab 2007a and 2007b:
[font=“Courier”]Szeta.cu
c:\cuda\include\common_functions.h(56): warning: dllexport/dllimport conflict
with “clock” (declared at line 176 of “C:\Program Files
(x86)\Microsoft Visual Studio 8\VC\BIN/…\INCLUDE\time.h”);
dllimport/dllexport dropped
tmpxft_00003104_00000000-3_Szeta.cudafe1.gpu
tmpxft_00003104_00000000-8_Szeta.cudafe2.gpu
c:\cuda\include\common_functions.h(56): warning: dllexport/dllimport conflict
with “clock” (declared at line 176 of “C:\Program Files
(x86)\Microsoft Visual Studio 8\VC\BIN/…\INCLUDE\time.h”);
dllimport/dllexport dropped
tmpxft_00003104_00000000-3_Szeta.cudafe1.cpp
cl : Command line warning D9025 : overriding ‘/EHc-’ with ‘/EHc’
Microsoft ® Incremental Linker Version 8.00.50727.42
Copyright © Microsoft Corporation. All rights reserved.
C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mex_82019D72-CB7F-4812-E09E-7579B5CBD19E\Szeta.obj
Creating library C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mex_82019D72-CB7F-4812-E09E-7579B5CBD19E\templib.x and object C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mex_82019D72-CB7F-4812-E09E-7579B5CBD19E\templib.exp
Szeta.obj : error LNK2001: unresolved external symbol _fltused
Szeta.obj : error LNK2001: unresolved external symbol __GSHandlerCheck
Szeta.obj : error LNK2019: unresolved external symbol __security_cookie referenced in function __device_stub__Z12non_linear_2PfP6float2S1_S1_fi
Szeta.obj : error LNK2019: unresolved external symbol __security_check_cookie referenced in function __device_stub__Z12non_linear_2PfP6float2S1_S1_fi
LINK : error LNK2001: unresolved external symbol _DllMainCRTStartup
Szeta.mexw64 : fatal error LNK1120: 5 unresolved externals
C:\PROGRA~1\MATLAB\R2007B\BIN\NVMEX.PL: Error: Link of ‘Szeta.mexw64’ failed.
??? Error using ==> nvmex at 206
Unable to complete successfully.[/font]
Is there any way to get CUDA to work with one of the last three versions of Matlab on a Windows XP x64 system?
Thanks ever so much for your help,
Rupert