GetArchVersion

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

Obtains the version number of the current AI processor architecture.

Prototype

1
__aicore__ inline void GetArchVersion(uint32_t& coreVersion)

Parameters

Parameter

Input/Output

Description

coreVersion

Output

AI processor architecture version

Data type: uint32_t

Returns

None

Constraints

Before calling GetArchVersion, define coreVersion. After GetArchVersion is called, coreVersion changes to the corresponding architecture version.

Due to hardware restrictions, you need to print the converted AI processor architecture version number as a hexadecimal number or directly convert it into a hexadecimal number.

Example

The following example shows how to obtain the AI processor architecture version number by calling GetArchVersion.
1
2
3
    uint32_t coreVersion = 0;// Define the AI processor version.
    AscendC::GetArchVersion(coreVersion);
    AscendC::PRINTF("core version is %x", coreVersion);// Use %x to print it as a hexadecimal number.

Different server models have different architecture version numbers.

Architecture Version Number

Model

200

Atlas inference product AI Core

220

Atlas A2 training product/Atlas A2 inference product

Atlas A3 training product/Atlas A3 inference product

Not officially determined yet. Refer to the final commercial version description.

Atlas 350 Accelerator Card