Free gpu memory.
| 197 | |
| 198 | /// Free gpu memory. |
| 199 | void CudaGPU::Free(void* ptr) { |
| 200 | if (ptr != nullptr) { |
| 201 | CUDA_CHECK(cudaSetDevice(id_)); |
| 202 | pool_->Free(ptr); |
| 203 | } |
| 204 | } |
| 205 | |
| 206 | void CudaGPU::Sync() { |
| 207 | Exec([this](Context* ctx) { CUDA_CHECK(cudaDeviceSynchronize()); }, {}, {}, |
nothing calls this directly
no outgoing calls
no test coverage detected