cubecl_hip_sys

Function hipMemPoolDestroy

Source
pub unsafe extern "C" fn hipMemPoolDestroy(
    mem_pool: hipMemPool_t,
) -> hipError_t
Expand description

@brief Destroys the specified memory pool

If any pointers obtained from this pool haven’t been freed or the pool has free operations that haven’t completed when @p hipMemPoolDestroy is invoked, the function will return immediately and the resources associated with the pool will be released automatically once there are no more outstanding allocations.

Destroying the current mempool of a device sets the default mempool of that device as the current mempool for that device.

@param [in] mem_pool Memory pool for destruction

@note A device’s default memory pool cannot be destroyed.

@returns #hipSuccess, #hipErrorInvalidValue

@see hipMallocFromPoolAsync, hipMallocAsync, hipFreeAsync, hipMemPoolGetAttribute, hipMemPoolCreate hipMemPoolTrimTo, hipDeviceSetMemPool, hipMemPoolSetAttribute, hipMemPoolSetAccess, hipMemPoolGetAccess

@warning : This API is marked as beta, meaning, while this is feature complete, it is still open to changes and may have outstanding issues.

@note This API is implemented on Linux, under development on Windows.