Op2StageExecuteFuncs

Function Usage

Sets operator-level callback functions in scenarios where a single operator contains multi-kernel execution logic. The setting includes the delivery preparation callback function and delivery callback function. The delivery preparation callback function prepares parameters to be used for multi-kernel delivery, and the delivery callback function implements this delivery. This is an internal API. It is not called directly by developers and requires no attention at this time.

Prototype

1
OpImplRegisterV2 &Op2StageExecuteFuncs(OpExecPrepareFunc prepare_func, OpExecLaunchFunc launch_func)

Parameters

Parameter

Input/Output

Description

prepare_func

Input

User-defined OpExecPrepareFunc function to be registered. It is of the OpExecPrepareFunc type.

The OpExecPrepareFunc type is defined as follows:

1
using OpExecPrepareFunc = UINT32 (*)(OpExecutePrepareContext *);

launch_func

Input

User-defined OpExecLaunchFunc function to be registered. It is of the OpExecLaunchFunc type.

1
using OpExecLaunchFunc = UINT32 (*)(OpExecuteLaunchContext *);

Returns

OpImplRegisterV2 object of the operator, where the operator-level callback function is registered.

Constraints

None