| 46 | |
| 47 | // This function wraps the CUDA Driver API into a template function |
| 48 | template <class T> inline void getCudaAttribute(T *attribute, CUdevice_attribute device_attribute, int device) |
| 49 | { |
| 50 | CUresult error = cuDeviceGetAttribute(attribute, device_attribute, device); |
| 51 | |
| 52 | if (CUDA_SUCCESS != error) { |
| 53 | fprintf( |
| 54 | stderr, "cuSafeCallNoSync() Driver API error = %04d from file <%s>, line %i.\n", error, __FILE__, __LINE__); |
| 55 | |
| 56 | exit(EXIT_FAILURE); |
| 57 | } |
| 58 | } |
| 59 | |
| 60 | #endif /* CUDART_VERSION < 5000 */ |
| 61 |
nothing calls this directly
no outgoing calls
no test coverage detected