GetValue

Product Support

Product

Supported

Atlas A3 training products/Atlas A3 inference products

Atlas A2 training products/Atlas A2 inference products

Atlas 200I/500 A2 inference products

Atlas inference product's AI Core

Atlas inference product's Vector Core

Atlas training products

Function

Obtains the value of the corresponding offset position of the GlobalTensor.

Prototype

1
__aicore__ inline __inout_pipe__(S) PrimType GetValue(const uint64_t offset) const

Parameters

Table 1 Parameters

Parameter

Input/Output

Description

offset

Input

Offsets offset elements.

Returns

Returns an immediate of the PrimType type.

Restrictions

If the content at the global memory address obtained by GetValue may be overwritten externally, call DataCacheCleanAndInvalid first to ensure cache coherence between the data cache and global memory, and then call this API.