atb/operation.h

Definition

1
2
Status SetExecuteStreamId(Operation *operation, uint32_t streamId);
uint32_t GetExecuteStreamId(Operation *operation);

Parameters

Member

Parameter

Return Value

Description

SetExecuteStreamId

operation

streamId

Status

This API is used to set the stream ID of an operation. During operation execution, the operation is executed in the entity stream corresponding to the context index based on the configured stream ID. The modification behavior of this API for a single operator is slightly different from that for a graph operator. When this API is called by a single operator, the stream ID of the single operator is changed. When this API is called by a graph operator, the stream IDs of all operators whose stream IDs are not set in the graph are changed.

GetExecuteStreamId

operation

uint32_t

This API is used to obtain the stream ID of an operation. The obtaining behavior of this API for a single operator is slightly different from that for a graph operator. When this API is called by a single operator, the stream ID of the current operator is obtained. When this API is called by a graph operator, the obtained stream ID of the graph operator is meaningless because the graph may contain nodes with different stream IDs and the stream ID of the graph operator cannot represent all related stream IDs.