pub unsafe extern "C" fn cuModuleUnload(hmod: CUmodule) -> CUresultExpand description
Unloads a module.
Unloads a module hmod from the current context. Attempting to unload a module which was obtained from the Library Management API such as cuLibraryGetModule will return cudaError_enum::CUDA_ERROR_NOT_PERMITTED.
Note that this function may also return error codes from previous, asynchronous launches.
Note: Use of the handle after this call is undefined behavior.
§Parameters
hmod: Module to unload
§Return value
CUresult::CUDA_SUCCESSCUresult::CUDA_ERROR_DEINITIALIZEDCUresult::CUDA_ERROR_NOT_INITIALIZEDCUresult::CUDA_ERROR_INVALID_CONTEXTCUresult::CUDA_ERROR_INVALID_VALUECUresult::CUDA_ERROR_NOT_PERMITTED
See also: cuModuleGetFunction, cuModuleGetGlobal, cuModuleGetTexRef, cuModuleLoad, cuModuleLoadData, cuModuleLoadDataEx, cuModuleLoadFatBinary.