Skip to main content

cudaDeviceGetLimit

Function cudaDeviceGetLimit 

Source
pub unsafe extern "C" fn cudaDeviceGetLimit(
    pValue: *mut size_t,
    limit: cudaLimit,
) -> cudaError_t
Expand description

Return resource limits.

Returns in *pValue the current size of limit. The following cudaLimit values are supported.

Note that this function may also return error codes from previous, asynchronous launches.

Note that this function may also return cudaError_t::CUDA_ERROR_NOT_INITIALIZED, cudaErrorInsufficientDriver or cudaError_t::CUDA_ERROR_NO_DEVICE if this call tries to initialize internal CUDA RT state.

Note that as specified by cudaStreamAddCallback no CUDA function may be called from callback. cudaError_t::CUDA_ERROR_NOT_PERMITTED may, but is not guaranteed to, be returned as a diagnostic in such case.

§Parameters

  • pValue: Returned size of the limit.
  • limit: Limit to query.

§Return value

See also: cudaDeviceSetLimit, cuCtxGetLimit.