ICachePreLoad (ISASI)

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

x

Atlas inference product AI Core

Atlas inference product Vector Core

x

Atlas training product

x

Function Usage

Preloads instructions to the iCache from the DDR address where the instructions are located.

Prototype

1
__aicore__ inline void ICachePreLoad(const int64_t preFetchLen)

Parameters

Table 1 Parameters

Parameter

Input/Output

Description

preFetchLen

Input

Prefetch length.

For the Atlas A2 training product/Atlas A2 inference product, the unit of preFetchLen is 2 KB. The value must be smaller than the iCache size/2 KB. The iCache sizes of the AIC and AIV are 32 KB and 16 KB, respectively.

For the Atlas A3 training product/Atlas A3 inference product, the unit of preFetchLen is 2 KB. The value must be smaller than the iCache size/2 KB. The iCache sizes of the AIC and AIV are 32 KB and 16 KB, respectively.

For the Atlas inference product AI Core, this parameter is invalid. The prefetch length is 128 bytes.

For the Atlas 350 Accelerator Card, the unit of preFetchLen is 2 KB. The value must be smaller than the iCache size/2 KB. The iCache sizes of the AIC and AIV are 32 KB and 16 KB, respectively.

Returns

None

Constraints

None

Example

1
2
int64_t preFetchLen = 2; // Prefetch length
AscendC::ICachePreLoad(preFetchLen);