跳转至

msptiBuffersCallbackRequestFunc

Supported Products

Note: For details about Ascend product models, see Ascend Product Models.

Product Type Supported
Ascend 950 products
Atlas A3 training series/Atlas A3 inference series
Atlas A2 training series/Atlas A2 inference series
Atlas 200I/500 A2 inference products
Atlas inference series ×
Atlas training series products ×

Description

Registers the callback function with MSPTI to allocate the storage space of the activity buffer. When using the Activity API, a user (subscriber) needs to customize this function and register it with MSPTI. When the storage space of the activity buffer is insufficient, MSPTI calls this function to allocate new storage space.

Function Prototype

typedef void(*msptiBuffersCallbackRequestFunc)(uint8_t **buffer, size_t *size, size_t *maxNumRecords)

Parameter Description

Table 1 Command-line options

Parameter Name

Input/Output

Description

buffer

Output

Sets the address of the activity buffer.

size

output.

Sets the size of the activity buffer. (You are advised to allocate at least 2 MB memory.)

maxNumRecords

output.

Sets the number of records in the activity buffer. The value is generally **0**.

Return Values

None