I am using an old PC with an old GPU card(GeForce 9800 GT).
As you may know, 9800 does not support "printf" function in device code.
However, Nvidia supplies cuPrintf. In CU file, it can be used like following.
The situation is how can I use "cudaPrintfInit, cudaPrintfDisplay and
cudaPrintfEnd" in Python code?
Thanks
[cu starts]
#include "cuPrintf.cu"
__global__ void my_kernel()
{
cuPrintf("x=%u, y=%u, offset=%u\t", x, y, offset);
}
int main()
{
cudaPrintfInit();
my_kernel<<<...>>>();
cudaPrintfDisplay(stdout, true);
cudaPrintfEnd();
}
[cu ends]_______________________________________________
PyCUDA mailing list
[email protected]
http://lists.tiker.net/listinfo/pycuda