AI Engine API User Guide (AIE-API) 2024.2
Loading...
Searching...
No Matches
Uility functions and classes

Overview

Modules

 Print functions
 These functions provide an abstraction on top of printf that allow users to display the contents of AIE types in the standard output.
 
 Loop unrolling functions
 These functions allow users to explicitly unroll the body of a loop.
 

Classes

struct  aie::arch
 Structure used to represent the AIE architecture being compiled against. More...
 

Class Documentation

◆ aie::arch

struct aie::arch

Structure used to represent the AIE architecture being compiled against.

Public Types

enum  ArchGeneration : unsigned
 An enum defining available AIE generations, which are defined as: More...
 
enum  ArchVersion : unsigned
 An enum defining available AIE architectures. More...
 

Static Public Member Functions

template<typename... T>
requires (std::is_same_v<T, ArchGeneration> && ...)
static constexpr bool is (T... gens)
 Checks if the current AIE architecture version against the supplied generation pack.
 
template<typename... T>
requires (std::is_same_v<T, ArchVersion> && ...)
static constexpr bool is (T... vs)
 Checks if the current AIE architecture version against the supplied pack.
 

Static Public Attributes

static constexpr ArchGeneration generation = ArchGeneration(__AIE_ARCH__ / 10)
 Represents the current AIE generation.
 
static constexpr ArchVersion version = ArchVersion(__AIE_ARCH__)
 Represents the current AIE architecture version.
 

Member Enumeration Documentation

◆ ArchGeneration

enum aie::arch::ArchGeneration : unsigned

An enum defining available AIE generations, which are defined as:

  • Gen1: AIE
  • Gen2: AIE-ML/XDNA 1
Enumerator
Gen1 
Gen2 

◆ ArchVersion

enum aie::arch::ArchVersion : unsigned

An enum defining available AIE architectures.

Enumerator
AIE 
AIE_ML 
XDNA_2 
AIE_MLv2 

Member Function Documentation

◆ is() [1/2]

template<typename... T>
requires (std::is_same_v<T, ArchGeneration> && ...)
static constexpr bool aie::arch::is ( T...  gens)
inlinestaticconstexpr

Checks if the current AIE architecture version against the supplied generation pack.

Parameters
vsA pack of ArchGenerations to test the current version against

◆ is() [2/2]

template<typename... T>
requires (std::is_same_v<T, ArchVersion> && ...)
static constexpr bool aie::arch::is ( T...  vs)
inlinestaticconstexpr

Checks if the current AIE architecture version against the supplied pack.

Parameters
vsA pack of ArchVersions to test the current version against

Member Data Documentation

◆ generation

constexpr ArchGeneration aie::arch::generation = ArchGeneration(__AIE_ARCH__ / 10)
staticconstexpr

Represents the current AIE generation.

◆ version

constexpr ArchVersion aie::arch::version = ArchVersion(__AIE_ARCH__)
staticconstexpr

Represents the current AIE architecture version.