pub unsafe extern "C" fn cuStreamBatchMemOp_v2(
stream: CUstream,
count: c_uint,
paramArray: *mut CUstreamBatchMemOpParams,
flags: c_uint,
) -> CUresult
Expand description
\brief Batch operations to synchronize the stream via memory operations
This is a batch version of ::cuStreamWaitValue32() and ::cuStreamWriteValue32(). Batching operations may avoid some performance overhead in both the API call and the device execution versus adding them to the stream in separate API calls. The operations are enqueued in the order they appear in the array.
See ::CUstreamBatchMemOpType for the full set of supported operations, and ::cuStreamWaitValue32(), ::cuStreamWaitValue64(), ::cuStreamWriteValue32(), and ::cuStreamWriteValue64() for details of specific operations.
See related APIs for details on querying support for specific operations.
\note Warning: Improper use of this API may deadlock the application. Synchronization ordering established through this API is not visible to CUDA. CUDA tasks that are (even indirectly) ordered by this API should also have that order expressed with CUDA-visible dependencies such as events. This ensures that the scheduler does not serialize them in an improper order. For more information, see the Stream Memory Operations section in the programming guide(https://docs.nvidia.com/cuda/cuda-c-programming-guide/index.html).
\param stream The stream to enqueue the operations in. \param count The number of operations in the array. Must be less than 256. \param paramArray The types and parameters of the individual operations. \param flags Reserved for future expansion; must be 0.
\return ::CUDA_SUCCESS, ::CUDA_ERROR_INVALID_VALUE, ::CUDA_ERROR_NOT_SUPPORTED \notefnerr
\sa ::cuStreamWaitValue32, ::cuStreamWaitValue64, ::cuStreamWriteValue32, ::cuStreamWriteValue64, ::cuMemHostRegister