| 27 | #ifdef WITH_CUDA |
| 28 | |
| 29 | bool HasCudaDevice() { |
| 30 | int device_count = 0; |
| 31 | if (cudaGetDeviceCount(&device_count) != cudaSuccess) { return false; } |
| 32 | if (device_count <= 0) { return false; } |
| 33 | return true; |
| 34 | } |
| 35 | |
| 36 | void TestCache(Cache* cache, uint32_t line_size) { |
| 37 | std::unique_ptr<ep::DeviceManagerRegistry> device_manager_registry( |