| 35 | : m_allocator{std::make_shared<DeviceMemoryAllocator>()} {} |
| 36 | |
| 37 | void StaticDeviceMemoryManager::exec_enter() { |
| 38 | auto flag = m_in_exec.test_and_set(); |
| 39 | mgb_assert(!flag, "double-lock on StaticDeviceMemoryManager"); |
| 40 | } |
| 41 | |
| 42 | void StaticDeviceMemoryManager::exec_exit() { |
| 43 | mgb_assert(m_in_exec.test_and_set()); |