Hi all,
我的程序在执行完一个kernel之后,要把一个float值复制给一个Host端的变量。
类似:
float res;
launch_kernel<<<…>> (…, float * data);
cutilSafeCall( cudaMemcpy( &res, data, sizeof(float), cudaMemcpyDeviceToHost) );
执行copy的时候会出错:
Runtime API error : the launch timed out and was terminated.
cutil提示的出错行数就是cudamemcpy这一行。
这样的问题怎么来解决呢?