DLL problem with cudaMallocPitch

Hello Everyone,

First, I made a simple CUDA program which works fine but when I try to do a DLL, the program running but stops at this line :
[indent]cutilSafeCall(cudaMallocPitch(&cu_fTemp, &pitch, iDim*sizeof(float), iDim));[/indent]with this error : “cudaSafeCall() Runtime API error : unspecified driver error”.

If I don’t use cudaMallocPitch but cudaMallocArray, there is the same problem:confused:
I have a gtx275 and I work with VS 2008 on Windows 7.

Any help is appreciated. Thanks in advance.

After several tests, it seems all functions which call texture memory doesn’t work. But the global memory and the shared memory work fine…
I’m lost. :pinch:

I’m doing the same thing in my library and it works fine. I grouped all GPU functions in a DLL which creates a thread for each GPU found in the computer so that only 1 thread handles all function calls for that GPU. I use all kinds of memory (textures, global, shared) and it works fine.

Maybe you can try in a different OS or something. I’m using CUDA 3.0 with driver 197.13 on Windows XP (32 bits) and it (nearly) works fine. OK I have some problems with function calls disabling OpenMP but that’s another story; GPU implementation itself works fine.

Indeed the problem was the driver version. To use Nexus I have to employ the driver 195.62 but it doesn’t work if I want to do a DLL.

Thanks a lot AlferDube for your help.