MCPcopy Create free account
hub / github.com/arrayfire/arrayfire / isDeviceBufferAccessible

Function isDeviceBufferAccessible

src/backend/opencl/platform.cpp:281–289  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

279}
280
281bool isDeviceBufferAccessible(int buf_device_id, int execution_id) {
282 DeviceManager& devMngr = DeviceManager::getInstance();
283
284 common::lock_guard_t lock(devMngr.deviceMutex);
285
286 return buf_device_id == execution_id ||
287 *devMngr.mContexts[buf_device_id] ==
288 *devMngr.mContexts[execution_id];
289}
290
291const Context& getContext() {
292 device_id_t& devId = tlocalActiveDeviceId();

Callers 1

checkAndMigrateFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected