hipStreamSynchronize

Function hipStreamSynchronize 

Source
pub unsafe extern "C" fn hipStreamSynchronize(
    stream: hipStream_t,
) -> hipError_t
Expand description

@brief Waits for all commands in the stream to complete.

@param[in] stream Stream identifier.

@returns #hipSuccess, #hipErrorInvalidHandle

This command is host-synchronous : the host will block until all operations on the specified stream with its associated device are completed. On multiple device systems, the @p stream is associated with its device, no need to call hipSetDevice before this API.

This command follows standard null-stream semantics. Specifying the null stream will cause the command to wait for other streams on the same device to complete all pending operations.

This command honors the #hipDeviceScheduleBlockingSync flag, which controls whether the wait is active or blocking.

@see hipStreamCreate, hipStreamCreateWithFlags, hipStreamCreateWithPriority, hipStreamWaitEvent, hipStreamDestroy