2

I am trying to compile my first CUDA 5.0 project I took the template sample. I have not gotten it to compile it yet and as it shows two errors, I have compared the project settings with those of the template project and they appear to be consistent so I'm stumped. Here are my two errors.

The first occurs when I try to call my kernwl it marks the '<<<'

Error 32 error : expected an expression D:\Virtualbox Data\Assembla\gul\antares software\AntaresVisualizerCuda\AntaresVisualizerCuda\kernel.cu 584

Its possible that thar would be fixed by solving the next error:

Error 33 error MSB3721: The command ""C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.0\bin\nvcc.exe" -gencode=arch=compute_10,code=\"sm_10,compute_10\" --use-local-env --cl-version 2010 -ccbin "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin" -I"./" -I"C:\ProgramData\NVIDIA Corporation\CUDA Samples\v5.0\C\common\inc" -I"C:\ProgramData\NVIDIA Corporation\CUDA Samples\v5.0\shared\inc" -I"C:\fltk-1.3.0\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.0\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.0\include" -I"C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.0\include" -G --keep-dir "Debug" -maxrregcount=0 --machine 32 --compile -g -DWIN32 -DWIN32 -DWIN32 -D_DEBUG -D_WINDOWS -D_MBCS -D_MBCS -Xcompiler "/EHsc /W3 /nologo /Od /Zi /RTC1 /MTd " -o "Win32/Debug/kernel.cu.obj" "D:\Virtualbox Data\Assembla\gul\antares software\AntaresVisualizerCuda\AntaresVisualizerCuda\kernel.cu"" exited with code 2. C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\BuildCustomizations\CUDA 5.0.targets 498

Any ideas on this one?

4

1 回答 1

2

您在评论中的内核调用如下所示:

tracePixel<<< gridP, threads >>>(d_screenOrigin, u_unit, d_u_dir, v_unit, d_v_dir, d_cam_pos, d_minpoint, d_maxpoint, gridLength, min, scale, d_grid, d_buffer,);

如果这确实是您所拥有的而不是拼写错误,那么就会有一个额外的“,”之后d_buffer不应该存在。要么,要么你错过了一个论点。

于 2012-10-23T18:40:51.353 回答