Skip to content

API & Internals

This section documents the full IRON / MLIR-AIE programming surface, from the high-level Python API you write designs in down to the low-level MLIR dialects and C++ compiler internals.

The stack is organized in layers. Most users only need the top layer; the lower layers are here for advanced designs, op-by-op construction, and compiler work.

The layers

Layer What it is When you reach for it
IRON (aie.iron) The high-level Python API. Every object is resolvable — it lowers to MLIR when compiled: @iron.jit, Worker, ObjectFifo, Runtime, Program, Buffer, Kernel, the tensor factories, and advanced primitives like Flow, TileDma, and Lock. Writing NPU designs. Start here.
Dialect op wrappers (aie.dialects.*) The low-level Python layer: thin wrappers around individual MLIR ops of the aie / aiex / aievec dialects. This is what aie.iron lowers to. Op-by-op construction, custom lowerings, reading emitted MLIR.
C++ AIE kernels (aie_kernels, AIE API) The per-core compute code that runs on an AIE tile, written in C++ with the AIE API header library or low-level intrinsics. Writing or tuning the vectorized math a Worker runs.
Utilities taplib tensor access patterns, the pre-built Python kernel library, and host-runtime helpers. Tiling / streaming descriptors, ready-made kernels, host glue.
MLIR / C++ The aie / aiex / aievec / adf dialect definitions, their passes, and the generated C++ API. Compiler internals, custom passes, dialect op reference.

Python API

  • IRON (aie.iron)


    The high-level user API. Program, Worker, ObjectFifo, Runtime, Buffer, Kernel, @iron.jit, the tensor factories, plus advanced resolvable primitives (Flow, TileDma, Lock).

  • Dialect op wrappers (aie.dialects.*)


    The low-level layer IRON lowers to: direct Python wrappers around the aie / aiex / aievec MLIR operations.

  • Tensor Access Patterns (taplib)


    TensorAccessPattern, TensorAccessSequence, and TensorTiler2D for describing how data is tiled and streamed.

  • Python Kernel Library


    Pre-built iron.kernels wrappers for element-wise, reduction, linalg, convolution, activation, and vision operations.

  • C++ AIE kernels


    The C++ compute code that runs on a tile — the aie_kernels library and the AIE API header library used to write it.

Low-level MLIR / C++

The compiler layer beneath the Python API. See the dialect and pass reference pages in the MLIR / C++ group of this section:


New to IRON? Start with the Programming Guide for worked examples, then use this section as a reference.