aclFinalizeCallbackRegister

Applicable Products

Product

Supported

Ascend 950PR/Ascend 950DT

√

Atlas A3 training products/Atlas A3 inference products

√

Atlas A2 training products/Atlas A2 inference products

√

Atlas 200I/500 A2 inference products

√

Atlas inference products

√

Atlas training products

√

Function

Registers a deinitialization callback function.

This API must be called before aclFinalize to trigger a callback function during deinitialization.

Prototype

1
aclError aclFinalizeCallbackRegister(aclRegisterCallbackType type, aclFinalizeCallbackFunc cbFunc, void *userData)

Parameters

Parameter

Input/Output

Description

type

Input

Registration type, which is distinguished by function. For details, see aclRegisterCallbackType.

cbFunc

Input

Deinitialization callback function.

Callback function definition:

typedef aclError (*aclFinalizeCallbackFunc)(void *userData);

userData

Input

Pointer to the user data to be passed to the callback function.

Returns

0 on success; otherwise, failure. For details, see aclError.