Friday, May 1, 2009

CUDA kernel errors

To print any errors that may be returned when you execute a kernel in a human readable way (you get the errors defined in the programming guide), add the following lines after your kernel call:

err = cudaGetLastError();
if (err != cudaSuccess) printf("%s\n", cudaGetErrorString( err ) );

1 comment:

  1. Kernel executions do not produce errors readable this way (or any other). This is explained in the programming manual.

    ReplyDelete