| 63 | |
| 64 | #ifdef CUDNN |
| 65 | cudnnHandle_t cudnn_handle() |
| 66 | { |
| 67 | static int init[16] = {0}; |
| 68 | static cudnnHandle_t handle[16]; |
| 69 | int i = cuda_get_device(); |
| 70 | if(!init[i]) { |
| 71 | cudnnCreate(&handle[i]); |
| 72 | init[i] = 1; |
| 73 | } |
| 74 | return handle[i]; |
| 75 | } |
| 76 | #endif |
| 77 | |
| 78 | cublasHandle_t blas_handle() |
no test coverage detected