![]() |
ONNX Runtime
|
Struct that an EP implements if it wishes to implement Stream support. More...
#include <onnxruntime_ep_c_api.h>
Public Member Functions | |
| OrtStatus * | CreateNotification (OrtSyncStreamImpl *this_ptr, OrtSyncNotificationImpl **notification) |
| Create an OrtSyncNotificationImpl for the OrtSyncStreamImpl instance. | |
| OrtStatus * | Flush (OrtSyncStreamImpl *this_ptr) |
| Flush the stream. | |
| OrtStatus * | OnSessionRunEnd (OrtSyncStreamImpl *this_ptr) |
| Notify the stream that a session run has ended. | |
Public Attributes | |
| uint32_t | ort_version_supported |
| Must be initialized to ORT_API_VERSION. | |
| void(* | Release )(OrtSyncStreamImpl *this_ptr) |
| Release the OrtSyncStreamImpl instance. | |
| void *(* | GetHandle )(OrtSyncStreamImpl *this_ptr) |
| Get the handle of the stream. | |
Struct that an EP implements if it wishes to implement Stream support.
This struct provides the overrides for onnxruntime::Stream's virtual methods.
| OrtStatus * OrtSyncStreamImpl::CreateNotification | ( | OrtSyncStreamImpl * | this_ptr, |
| OrtSyncNotificationImpl ** | notification | ||
| ) |
Create an OrtSyncNotificationImpl for the OrtSyncStreamImpl instance.
| [in] | this_ptr | Pointer to the OrtSyncStreamImpl instance |
| [out] | notification | The new OrtSyncNotificationImpl instance. |
| OrtStatus * OrtSyncStreamImpl::Flush | ( | OrtSyncStreamImpl * | this_ptr | ) |
Flush the stream.
This is called by ORT to flush the stream, ensuring that all operations submitted to the stream are completed.
| [in] | this_ptr | Pointer to the OrtSyncStreamImpl instance. |
| OrtStatus * OrtSyncStreamImpl::OnSessionRunEnd | ( | OrtSyncStreamImpl * | this_ptr | ) |
Notify the stream that a session run has ended.
This is called by ORT to notify the stream that a session run has ended, allowing the stream to perform any necessary cleanup or finalization.
| [in] | this_ptr | Pointer to the OrtSyncStreamImpl instance. |
| void *( * OrtSyncStreamImpl::GetHandle) (OrtSyncStreamImpl *this_ptr) |
Get the handle of the stream.
This returns the native handle for the stream. e.g. cudaStream_t for CUDA streams.
| [in] | this_ptr | Pointer to the OrtSyncStreamImpl instance. |
| uint32_t OrtSyncStreamImpl::ort_version_supported |
Must be initialized to ORT_API_VERSION.
| void( * OrtSyncStreamImpl::Release) (OrtSyncStreamImpl *this_ptr) |
Release the OrtSyncStreamImpl instance.
This is called by ORT when the OrtSyncStreamImpl instance is no longer needed. The implementation should release any resources held by the instance.
| [in] | this_ptr | Pointer to the OrtSyncStreamImpl instance. |