|
HIP: Heterogenous-computing Interface for Portability
|
Functions | |
| hipError_t | hipStreamCreateWithFlags (hipStream_t *stream, unsigned int flags) |
| Create an asynchronous stream. More... | |
| hipError_t | hipStreamWaitEvent (hipStream_t stream, hipEvent_t event, unsigned int flags) |
| Make the specified compute stream wait for an event. More... | |
| hipError_t | hipStreamSynchronize (hipStream_t stream) |
| Wait for all commands in stream to complete. More... | |
| hipError_t | hipStreamDestroy (hipStream_t stream) |
| Destroys the specified stream. More... | |
| hipError_t | hipStreamGetFlags (hipStream_t stream, unsigned int *flags) |
| Return flags associated with this stream. More... | |
The following Stream APIs are not (yet) supported in HIP:
| hipError_t hipStreamCreateWithFlags | ( | hipStream_t * | stream, |
| unsigned int | flags | ||
| ) |
Create an asynchronous stream.
| [in,out] | stream | Pointer to new stream |
| [in] | flags | to control stream creation. |
Create a new asynchronous stream. stream returns an opaque handle that can be used to reference the newly created stream in subsequent hipStream* commands. The stream is allocated on the heap and will remain allocated
even if the handle goes out-of-scope. To release the memory used by the stream, applicaiton must call hipStreamDestroy. Flags controls behavior of the stream. See hipStreamDefault, hipStreamNonBlocking. hipStream_t are under development - with current HIP use the NULL stream.
| hipError_t hipStreamDestroy | ( | hipStream_t | stream | ) |
Destroys the specified stream.
| [in,out] | stream | Valid pointer to hipStream_t. This function writes the memory with the newly created stream. |
Destroys the specified stream.
If commands are still executing on the specified stream, some may complete execution before the queue is deleted.
The queue may be destroyed while some commands are still inflight, or may wait for all commands queued to the stream before destroying it.
| hipError_t hipStreamGetFlags | ( | hipStream_t | stream, |
| unsigned int * | flags | ||
| ) |
Return flags associated with this stream.
| [in] | stream | |
| [in,out] | flags |
Return flags associated with this stream in *flags.
| hipError_t hipStreamSynchronize | ( | hipStream_t | stream | ) |
Wait for all commands in stream to complete.
If the null stream is specified, this command blocks until all
This command honors the hipDeviceLaunchBlocking flag, which controls whether the wait is active or blocking.
This command is host-synchronous : the host will block until the stream is empty.
TODO
| hipError_t hipStreamWaitEvent | ( | hipStream_t | stream, |
| hipEvent_t | event, | ||
| unsigned int | flags | ||
| ) |
Make the specified compute stream wait for an event.
| [in] | stream | stream to make wait. |
| [in] | event | event to wait on |
| [in] | flags | control operation [must be 0] |
This function inserts a wait operation into the specified stream. All future work submitted to stream will wait until event reports completion before beginning execution. This function is host-asynchronous and the function may return before the wait has completed.
1.8.6