| 186 | Allocator::Allocator() { logger = common::loggerFactory("mem"); } |
| 187 | |
| 188 | void Allocator::shutdown() { |
| 189 | for (int n = 0; n < opencl::getDeviceCount(); n++) { |
| 190 | try { |
| 191 | opencl::setDevice(n); |
| 192 | shutdownMemoryManager(); |
| 193 | } catch (const AfError &err) { |
| 194 | continue; // Do not throw any errors while shutting down |
| 195 | } |
| 196 | } |
| 197 | } |
| 198 | |
| 199 | int Allocator::getActiveDeviceId() { return opencl::getActiveDeviceId(); } |
| 200 |
no test coverage detected