Error Code 30 cudaError_t


I’m receiving an error code of 30 during a cudaThreadSynchronize() after my kernel launch. Can any one tell this error code refers to ?

Suresh Kumar.

const char* cudaGetErrorString(cudaError_t err) sure can!

I get “unknown error” :(

Then there is probably something wrong with your setup. I imagine it’s a mismatch between CUDA toolkit version and CUDA driver version (e.g., you’re using a 180.xx driver and the 2.2 toolkit instead of a 185.xx driver and the 2.2 toolkit).

Driver version is 186.18 . Tool kits I have seen this error are 2.1 and 2.3.

Btw, Can you point me to a resource that will describe me the compatibility between driver version and toolkit versions. For example can I use a newer toolkit on a older driver ?


Suresh Kumar.

Is there such a resource? I’m getting the same error, and am running out of ideas to what the cause might be.

The error shows up after a few kernel launches on my regular machine. The same program runs fine on my laptop.

Regular machine runs the examples of the GPU Computing Toolkit without any problems (at least the ones I’ve tried).

Regular machine has a GTX580 with driver version 270.81; Toolkit v4.0 (64bit); Win7 Prof (64bit).

Laptop has a Quadro FX 880 with driver version 275.33; Toolkit v4.0 (64bit); Win7 Prof (64bit).

Program is compiled as 32bit.

Any other possible reasons for this error?

Even more frustrating is that when I plug in another card (GeForce 210), and switch over to that card by using cudaSetDevice(), everything works again…

Look for out of bound memory accesses in shared memory.
Have you tried cuda-memcheck?

Sorry for my late reply.

Thank you for you reply! You were right indeed, I did have some out of bound memory access which needed fixing.

cuda-memcheck now reports 0 errors. Strange that this doesn’t cause the same errors on my other two devices.

However, I now get the “unknown error” after a Grid Launch Failure.

Program still seems to run okay on the secondary GPU (GeForce 210).

What reasons for a grid launch failure are there? Although I have to double check, I don’t think the problem is

using an invalid grid/block dimension, or using too much SharedMem/threads per block.