pub unsafe extern "C" fn cuMemImportFromShareableHandle(
handle: *mut CUmemGenericAllocationHandle,
osHandle: *mut c_void,
shHandleType: CUmemAllocationHandleType,
) -> CUresult
Expand description
\brief Imports an allocation from a requested shareable handle type.
If the current process cannot support the memory described by this shareable handle, this API will error as ::CUDA_ERROR_NOT_SUPPORTED.
If \p shHandleType is ::CU_MEM_HANDLE_TYPE_FABRIC and the importer process has not been granted access to the same IMEX channel as the exporter process, this API will error as ::CUDA_ERROR_NOT_PERMITTED.
\note Importing shareable handles exported from some graphics APIs(VUlkan, OpenGL, etc) created on devices under an SLI group may not be supported, and thus this API will return CUDA_ERROR_NOT_SUPPORTED. There is no guarantee that the contents of \p handle will be the same CUDA memory handle for the same given OS shareable handle, or the same underlying allocation.
\param[out] handle - CUDA Memory handle for the memory allocation. \param[in] osHandle - Shareable Handle representing the memory allocation that is to be imported. \param[in] shHandleType - handle type of the exported handle ::CUmemAllocationHandleType. \returns ::CUDA_SUCCESS, ::CUDA_ERROR_INVALID_VALUE, ::CUDA_ERROR_NOT_INITIALIZED, ::CUDA_ERROR_DEINITIALIZED, ::CUDA_ERROR_NOT_PERMITTED, ::CUDA_ERROR_NOT_SUPPORTED
\sa ::cuMemExportToShareableHandle, ::cuMemMap, ::cuMemRelease