Compilation error: .

Mar 3, 2014 at 12:37 PM
Hi,

I am trying to play around with CUDAfy.NET and here is my simple code:

CudafyModule km = CudafyTranslator.Cudafy(); //error occur here
GPGPU gpu = CudafyHost.GetDevice(eGPUType.Cuda);
gpu.LoadModule(km);

I am getting the following error at the first line of code:

CudafyCompileException was unhandled.
An unhandled exception of type 'Cudafy.CudafyCompileException' occurred in Cudafy.NET.dll

Additional information: Compilation error: .


Then, I run the Cudafy Viewer to test my CUDA set-up, I get the following log:

Platform=x64
Checking for CUDA SDK at C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v5.5\bin\nvcc
CUDA SDK Version=5.5
Attempting to cudafy a kernel function.
Successfully translated to CUDA C.
Attempting to compile CUDA C code.
Compilation error: .


Anyone know what is my problem? Anyway, I am using GTX780Ti, I got warning about my GPU is not compatible with CUDA Toolkit 5.5. Is it the root cause?
Coordinator
Mar 5, 2014 at 9:00 AM
That is a strange warning but I doubt that is related to this error since the compilation does not have anything to do with the target GPU. Can you get the CudafyByExample project to run successfully. A golden rule in programming is to always test the "out of the box" sample code before running your own.
Mar 30, 2014 at 8:18 AM
Edited Mar 30, 2014 at 8:43 AM
I have the same error and I'm using 780ti too. I'm trying to run the cudafy examples, but always getting the compilation error. (Compilation error: . )
also, i'm trying to configure PATH and nvсc.profile, but nothing changes.
Oct 4, 2014 at 6:30 PM
Same error running Cudafy Viewer, different parts:

"Check for CUDA"

Found 1 devices.

Name: GeForce GT 555M
Compute capability: 2.1

"Run CUDA Test"

Platform=x64
Checking for CUDA SDK at C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v6.5\bin\nvcc
CUDA SDK Version=6.5
Attempting to cudafy a kernel function.
Successfully translated to CUDA C.
Attempting to compile CUDA C code.
Compilation error: .


Here is my %PATH%

Path=C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v6.5\bin;C:\Program File
s\NVIDIA GPU Computing Toolkit\CUDA\v6.5\libnvvp;;;C:\Program Files (x86)\NVIDIA
Corporation\PhysX\Common;C:\Program Files (x86)\RSA SecurID Token Common;C:\Pro
gram Files (x86)\Windows Resource Kits\Tools\;C:\Windows\system32;C:\Windows;C:\
Windows\System32\Wbem;C:\Program Files\Microsoft Windows Performance Toolkit\;C:
\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommo
n\;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\WindowsPowerS
hell\v1.0\;C:\Program Files\Windows Fabric\bin\Fabric\Fabric.Code.1.0;C:\Program
Files (x86)\Common Files\Roxio Shared\DLLShared\;C:\Program Files (x86)\Common
Files\Roxio Shared\OEM\DLLShared\;C:\Program Files (x86)\Common Files\Roxio Shar
ed\OEM\DLLShared\;C:\Program Files (x86)\Common Files\Roxio Shared\OEM\12.0\DLLS
hared\;C:\Program Files (x86)\Roxio\OEM\AudioCore\;C:\Windows\System32\WindowsPo
werShell\v1.0\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Fil
es (x86)\Microsoft SDKs\Windows Azure\CLI\wbin;C:\Program Files\Microsoft SQL Se
rver\120\DTS\Binn\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\110\Too
ls\Binn\;C:\Program Files (x86)\Microsoft SQL Server\120\Tools\Binn\;C:\Program
Files\Microsoft SQL Server\120\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL
Server\120\Tools\Binn\ManagementStudio\;C:\Program Files (x86)\Microsoft SQL Ser
ver\120\DTS\Binn\;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance To
olkit\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x
86)\Microsoft SDKs\TypeScript\1.0\;C:\Program Files (x86)\Microsoft ASP.NET\ASP.
NET Web Pages\v1.0\
Oct 4, 2014 at 6:53 PM
[ From https://cudafy.codeplex.com/discussions/349808 ]

I had to add the VS2013 paths in my user profile for "Path":

C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN;C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools;

This appears to fix CUDAfy viewer (with the known exception for math libraries) :

Platform=x64
Checking for CUDA SDK at C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v6.5\bin\nvcc
CUDA SDK Version=6.5
Attempting to cudafy a kernel function.
Successfully translated to CUDA C.
Attempting to compile CUDA C code.
Successfully compiled CUDA C into a module.
Attempting to instantiate CUDA device object (GPGPU).
Successfully got CUDA device 0.
Attempting to load module.
Successfully loaded module.
Attempting to transfer data to GPU.
Successfully transferred data to GPU.
Attempting to launch function on GPU.
Successfully launched function on GPU.
Attempting to transfer results back from GPU.
Successfully transferred results from GPU.
Testing results.
Successfully tested results.
Checking for math libraries (FFT, BLAS, SPARSE, RAND).
Unable to load DLL 'cufft64_60': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
Oct 7, 2014 at 8:41 PM
Hi
I suspect this is the same old problem of not properly capturing the output of an external process. It's actually a tricky matter to capture both stdout and error streams without creating a deadlock.
Coordinator
Oct 8, 2014 at 6:28 AM
Correct. A fix has been added to correctly display the error message. Committed to version control and it will be in the next release (which also supports CUDA 6.5 runtime and maths libraries)