aclrtCmoAsyncWithDesc

Applicability

Product

Supported

Atlas 350 Accelerator Card

Atlas A3 training product/Atlas A3 inference product

Atlas A2 training product/Atlas A2 inference product

Atlas 200I/500 A2 inference product

Atlas inference product

Atlas training product

Description

Uses a memory descriptor (level-2 pointer mode) to operate the cache memory on the device. This API is asynchronous.

Prototype

1
aclError aclrtCmoAsyncWithDesc(void *cmoDesc, aclrtCmoType cmoType, aclrtStream stream, const void *reserve)

Parameters

Parameter

Input/Output

Description

cmoDesc

Input

Pointer to the address of the cache memory descriptor. This address is the memory address on the device.

Call aclrtCmoSetDesc to set the memory descriptor, and then pass the pointer of the memory descriptor address as an input parameter.

cmoType

Input

Cache memory operation type. For details about the type definition, see aclrtCmoType.

Currently, only ACL_RT_CMO_TYPE_PREFETCH (memory prefetch) is supported.

stream

Input

Stream for executing the memory operation task. For details about the type definition, see aclrtStream.

reserve

Input

Reserved. Currently, the value is fixed to NULL.

Returns

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