Tests/Cuda: Add identifiers to error messages

This commit is contained in:
Pierre Moreau 2017-02-02 23:22:16 +01:00 committed by Brad King
parent 84f3c87b03
commit eebb2be8b0
2 changed files with 4 additions and 2 deletions

View File

@ -28,6 +28,7 @@ EXPORT void cuda_dynamic_lib_func()
cudaError_t err = cudaGetLastError();
if(err != cudaSuccess)
{
std::cerr << cudaGetErrorString(err) << std::endl;
std::cerr << "DetermineIfValidCudaDevice [SYNC] failed: "
<< cudaGetErrorString(err) << std::endl;
}
}

View File

@ -22,7 +22,8 @@ int file3_launch_kernel(int x)
cudaError_t err = cudaGetLastError();
if(err != cudaSuccess)
{
std::cerr << cudaGetErrorString(err) << std::endl;
std::cerr << "file3_kernel [SYNC] failed: "
<< cudaGetErrorString(err) << std::endl;
return x;
}
return r.sum;