I am trying to resolve a CUDA runtime error. Debug information reported by cuda-gdb (with cuda-memcheck on):
warning: Cuda API error detected: cudaLaunch returned (0xb)
warning: Cuda API error detected: cudaGetLastError returned (0xb)
[Thread 0x7fa1a28c5700 (LWP 43041) exited]
[Thread 0x7fa1a16a5700 (LWP 43042) exited]
[Thread 0x7fa18df0e700 (LWP 43056) exited]
I have checked the block, grid dimensions, and the size of the dynamic shared memory being used, they are well below the limit. Please tell me what (0xb) error type stands for, I didn't find it in the cuda documentation. Also, please tell me any suggestion on how to solve this issue?
Device : Kepler K20 (CC=3.5) and CUDA 5.5
Code is too big to paste here.
If you do proper cuda error checking in your code, you can retrieve that 0xb error that is being reported from a cudaGetLastError
call, and pass it to a decoder (cudaGetErrorString
) that will tell you something more meaningful.
CUDA runtime API error codes are enumerated in driver_types.h
, which on a standard linux install will be in /usr/local/cuda/include
Search on cudaSuccess
which will be the first enumerated type (i.e. 0) then continue on until you find your error number.
In this case 0xb
(= 11) refers to cudaErrorInvalidValue
:
/**
* This indicates that one or more of the parameters passed to the API call
* is not within an acceptable range of values.
*/
cudaErrorInvalidValue = 11,