Command List#
oneAPI Level Zero Specification - Version 1.18.31
Command List Functions#
zetCommandListAppendMetricStreamerMarker#
Added in version 1.0
-
ZE_APIEXPORT ze_result_t ZE_APICALL zetCommandListAppendMetricStreamerMarker(zet_command_list_handle_t hCommandList, zet_metric_streamer_handle_t hMetricStreamer, uint32_t value)#
Append metric streamer marker into a command list.
The application must ensure the metric streamer is accessible by the device on which the command list was created.
The application must ensure the command list and metric streamer were created on the same context.
The application must not call this function from simultaneous threads with the same command list handle.
Allow to associate metric stream time based metrics with executed workload.
- Parameters:
hCommandList – [in] handle of the command list
hMetricStreamer – [in] handle of the metric streamer
value – [in] streamer marker value
- Returns:
ZE_RESULT_ERROR_INVALID_NULL_HANDLE
nullptr == hCommandListnullptr == hMetricStreamer
zetCommandListAppendMetricQueryBegin#
Added in version 1.0
-
ZE_APIEXPORT ze_result_t ZE_APICALL zetCommandListAppendMetricQueryBegin(zet_command_list_handle_t hCommandList, zet_metric_query_handle_t hMetricQuery)#
Appends metric query begin into a command list.
The application must ensure the metric query is accessible by the device on which the command list was created.
The application must ensure the command list and metric query were created on the same context.
This command blocks all following commands from beginning until the execution of the query completes.
The application must not call this function from simultaneous threads with the same command list handle.
- Parameters:
hCommandList – [in] handle of the command list
hMetricQuery – [in] handle of the metric query
- Returns:
ZE_RESULT_ERROR_INVALID_NULL_HANDLE
nullptr == hCommandListnullptr == hMetricQuery
zetCommandListAppendMetricQueryEnd#
Added in version 1.0
-
ZE_APIEXPORT ze_result_t ZE_APICALL zetCommandListAppendMetricQueryEnd(zet_command_list_handle_t hCommandList, zet_metric_query_handle_t hMetricQuery, ze_event_handle_t hSignalEvent, uint32_t numWaitEvents, ze_event_handle_t *phWaitEvents)#
Appends metric query end into a command list.
The application must ensure the metric query and events are accessible by the device on which the command list was created.
The application must ensure the command list, events and metric query were created on the same context.
The duration of the signal event created from an event pool that was created using ZE_EVENT_POOL_FLAG_KERNEL_TIMESTAMP flag is undefined. However, for consistency and orthogonality the event will report correctly as signaled when used by other event API functionality.
If numWaitEvents is zero, then all previous commands are completed prior to the execution of the query.
If numWaitEvents is non-zero, then all phWaitEvents must be signaled prior to the execution of the query.
This command blocks all following commands from beginning until the execution of the query completes.
The application must not call this function from simultaneous threads with the same command list handle.
- Parameters:
hCommandList – [in] handle of the command list
hMetricQuery – [in] handle of the metric query
hSignalEvent – [in][optional] handle of the event to signal on completion
numWaitEvents – [in] must be zero
phWaitEvents – [in][mbz] must be nullptr
- Returns:
ZE_RESULT_ERROR_INVALID_NULL_HANDLE
nullptr == hCommandListnullptr == hMetricQuery
(nullptr == phWaitEvents) && (0 < numWaitEvents)
zetCommandListAppendMetricMemoryBarrier#
Added in version 1.0
-
ZE_APIEXPORT ze_result_t ZE_APICALL zetCommandListAppendMetricMemoryBarrier(zet_command_list_handle_t hCommandList)#
Appends metric query commands to flush all caches.
The application must not call this function from simultaneous threads with the same command list handle.
- Parameters:
hCommandList – [in] handle of the command list
- Returns:
ZE_RESULT_ERROR_INVALID_NULL_HANDLE
nullptr == hCommandList