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

Function deleteDevice

include/af/oneapi.h:266–270  ·  view source on GitHub ↗

Remove the user provided device control constructs from the ArrayFire device manager pool This function should be used only when the user would like ArrayFire to remove an already pushed user generated OpenCL context and related objects. \param[in] dev is the OpenCL device id that has to be popped \param[in] ctx is the cl_context object to be removed from ArrayFire pool \note Arr

Source from the content-addressed store, hash-verified

264 \note ArrayFire does not take control of releasing the objects passed to it. The user needs to release them appropriately.
265*/
266static inline void deleteDevice(cl_device_id dev, cl_context ctx)
267{
268 af_err err = afcl_delete_device_context(dev, ctx);
269 if (err!=AF_SUCCESS) throw af::exception("Failed to remove the requested device from ArrayFire device pool");
270}
271#endif
272
273

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected