capture kernel error
| 77 | |
| 78 | // capture kernel error |
| 79 | inline void get_kernel_launch_err() { |
| 80 | cudaError_t err = cudaGetLastError(); |
| 81 | if (err != cudaSuccess) { |
| 82 | std::cerr << "CUDA Error: " << cudaGetErrorString(err) << std::endl; |
| 83 | } |
| 84 | cudaDeviceSynchronize(); // Ensure all preceding CUDA calls have completed |
| 85 | return; |
| 86 | } |
| 87 | |
| 88 | |
| 89 | #endif |
nothing calls this directly
no outgoing calls
no test coverage detected