Open toolset for developing, loading, and occupying AMD AI Engine programs on Ryzen AI NPUs.
This is not a model compiler. It is not FastFlowLM. It is the missing Linux path to write IRON/Peano tile kernels, keep two processes from clobbering a loaded design, and check whether the NPU is actually usable.
Supported target today: Krackan Point / NPU6 (1022:17f0 rev 0x20, IRON npu2 / aie2p). Other AMD NPUs may show up in ironlab doctor; they are not a compile/load guarantee.
Parakeet ASR is a first-party operator set in this lab (operators/), not the product. A host that wants transcription (Papyrus) will load a bundle later.
License: MIT OR Apache-2.0.
| Piece | Status |
|---|---|
just check / ironlab doctor |
NPU6 present, firmware, amdxdna, memlock, XRT 2.21.75 |
just hello |
vector-add on the NPU |
| dwconv 1D (C=1024, K=9, T=32 and T=375) | bit-exact vs NumPy |
| Occupancy | XRT allows two processes to run kernels at once (load_axlf ENOTSUP). Advisory flock is the protection. |
| Full Parakeet encoder / audio→text | not built |
cargo run -p ironlab -- doctor --plain
cargo run -p ironlab -- status --plain
cargo run -p ironlab -- load path/to/design.xclbin # holds until Ctrl-Cironlab load takes an exclusive occupancy lock, then tries xrtDeviceLoadXclbinFile. On XDNA that load currently returns ENOTSUP (NPU is not a classic FPGA bitstream). The lock still matters: IRON/NPUKernel will happily run two clients at once and clobber the array.
just install-toolchain # userspace: uv, mlir-aie source, pyxrt
just check
just hello
ironlab init my_op
# edit operators/my_op/{op,design,reference,test}.py
# add aie_kernels/aie2p/my_op.cc
just run operators/dwconv_1d/design.py --no-run
just test tests/correctness/ # skip NPU with --no-npuOperator layout (same as amd/IRON): see operators/README.md.
Do not use uv run — it can reinstall a mismatched mlir-aie wheel over the source build. Use just run / just test.
Four pieces must version-match: amdxdna kernel module, XRT userspace, XRT XDNA plugin, NPU firmware. In-tree Linux amdxdna can lag userspace and fail with mailbox EINVAL. Firmware name npu.dev.sbin vs npu.sbin is a real split. RLIMIT_MEMLOCK must be unlimited or xclbin load fails with EPERM.
ironlab doctor prints hints for apt / dnf / pacman / zypper. Arch is one tested distro, not the identity of the project.
Pins used here: XRT 2.21.75, Peano (llvm-aie) nightly wheel in pyproject.toml, mlir-aie built from source under third_party/ (gitignored — clone at install).
- Xilinx/mlir-aie — compiler / IRON
- amd/IRON — LLM operator library on the same compiler
- Scottcjn/open-xdna — XDNA1 Linux bring-up
- ryzen-npu-linux — IREE+IRON pins (Krackan not mapped there)
Public repo: WorldTreeNetwork/iron-lab. Site: worldtreenetwork.github.io/iron-lab. This tree is the lab. Do not vendor third_party/ (see toolchain-pins.toml + just fetch-sources). Dual MIT/Apache already in-tree.