aclrtcCompileProg

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

x

Atlas inference product 's AI Core

x

Atlas inference product 's Vector Core

x

Atlas training products

x

Function

Compiles a specified program.

Prototype

1
aclError aclrtcCompileProg(aclrtcProg prog, int numOptions, const char **options)

Parameters

Table 1 API parameters

Parameter

Input/Output

Description

prog

Input

Handle to the runtime compiler.

numOptions

Input

Number of compilation options.

options

Input

Compilation option array, which stores specific compilation options (the -std=c++17 option is added by default).

For details about the supported compilation options, see Compilation Options.

Returns

aclError is an int variable. For details, see RTC Error Codes.

Restrictions

None

Example

1
2
3
4
aclrtcProg prog;
const char *options[] = {"--npu-arch=dav-2201"};
int numOptions = sizeof(options) / sizeof(options[0]);
aclError result = aclrtcCompileProg(prog, numOptions, options);