Skip to main content

Module tensix

Module tensix 

Source
Expand description

Tensix (TT-Metalium) lowering of the spatial IR. Every kernel — reader, compute, writer — is PRINTED from the schedule; no vendor kernel is wired by path, and every construct the artifact carries is the image of an IR object (the choreography census is a bijection, locked).

The lowering reads only the verified program and its target: buffers → circular buffers (cb.rs: one CircularBufferConfig per buffer template); programs → kernels (roles.rs: equal engine signatures share one source — the vendor’s four reader variants are DERIVED, not enumerated); site data → runtime args (args.rs: one layout drives both the kernel text and the host loop); ops → C++ (kernel.rs: every ChoreoOp is one statement kind); the whole → host + CMake + a C oracle (host.rs, oracle.rs).

Structs§

ArgSlot
CbPlan
CbSlot
Kernel
One kernel SOURCE and its launches: a launch is a CreateKernel on one NOC over the maximal rectangles of the sites it covers (the writer of a 2-D GEMM is one source launched on both NOCs).
KernelClass
One kernel source: a signature class of engine programs, launched once per NOC it runs on.
Launch
RuntimeArgLayout
TensixArtifact
TensixBackend

Enums§

ArgSource
KernelRole

Functions§

bundle_dir_files
Every file a standalone bundle directory needs (the measure harness writes these verbatim).
bundle_files
The files of a bundle as (relative path, contents) — the ledger hashes exactly these.
mcast_corners
The multicast rectangle of a site’s receivers for operand, as (start, end) corners for a kernel on noc: NOC 0 travels toward larger coordinates and takes the near corner first; NOC 1 travels the other way and takes the far corner first (the vendor’s right → left+1, bottom → top+1). The simulator refuses a rectangle given against its NOC’s direction.