| 21 | #include "tensor_tools.h" |
| 22 | |
| 23 | static const char* cudnn_get_error_string(cudnnStatus_t s) |
| 24 | { |
| 25 | switch(s) |
| 26 | { |
| 27 | case CUDNN_STATUS_NOT_INITIALIZED: |
| 28 | return "CUDA Runtime API initialization failed."; |
| 29 | case CUDNN_STATUS_ALLOC_FAILED: |
| 30 | return "CUDA Resources could not be allocated."; |
| 31 | case CUDNN_STATUS_BAD_PARAM: |
| 32 | return "CUDNN_STATUS_BAD_PARAM"; |
| 33 | case CUDNN_STATUS_EXECUTION_FAILED: |
| 34 | return "CUDNN_STATUS_EXECUTION_FAILED"; |
| 35 | case CUDNN_STATUS_NOT_SUPPORTED: |
| 36 | return "CUDNN_STATUS_NOT_SUPPORTED"; |
| 37 | case CUDNN_STATUS_ARCH_MISMATCH: |
| 38 | return "CUDNN_STATUS_ARCH_MISMATCH: Your GPU is too old and not supported by cuDNN"; |
| 39 | default: |
| 40 | return "A call to cuDNN failed"; |
| 41 | } |
| 42 | } |
| 43 | |
| 44 | // Check the return value of a call to the cuDNN runtime for an error condition. |
| 45 | #define CHECK_CUDNN(call) \ |
nothing calls this directly
no outgoing calls
no test coverage detected