aclrtProcessHostFunc

The Atlas 200/300/500 Inference Product does not support this API.

The Atlas Training Series Product does not support this API.

Description

Triggers callback handling after a specified period. The thread specified by aclrtSubscribeHostFunc handles the callback.

You need to create a thread in advance and customize the thread function. This API is called in the thread function. After a specified period of time, the operator computation is performed in the system.

Prototype

aclError aclrtProcessHostFunc(int32_t timeout)

Parameters

Parameter

Input/Output

Description

timeout

Input

Timeout period (ms).

Value range:

  • –1: infinite wait.
  • Values greater than 0 (excluding 0): the wait period.

Returns

The value 0 indicates success, and other values indicate failure. For details, see aclError.