cubecl_hip_sys

Function hipCtxGetApiVersion

Source
pub unsafe extern "C" fn hipCtxGetApiVersion(
    ctx: hipCtx_t,
    apiVersion: *mut c_int,
) -> hipError_t
Expand description

@brief Returns the approximate HIP api version.

@param [in] ctx Context to check @param [out] apiVersion API version to get

@return #hipSuccess

@warning The HIP feature set does not correspond to an exact CUDA SDK api revision. This function always set *apiVersion to 4 as an approximation though HIP supports some features which were introduced in later CUDA SDK revisions. HIP apps code should not rely on the api revision number here and should use arch feature flags to test device capabilities or conditional compilation.

@see hipCtxCreate, hipCtxDestroy, hipCtxGetDevice, hipCtxGetFlags, hipCtxPopCurrent, hipCtxPushCurrent, hipCtxSetCacheConfig, hipCtxSynchronize, hipCtxGetDevice

@warning This API is deprecated on the AMD platform, only for equivalent cuCtx driver API on the NVIDIA platform.