CUDA Programming Guide#
Note
Native-level kernel authoring for the CUDA backend (the "cuda"
target): the thread hierarchy, memory scopes, the Tx.cuda.* / Tx.ptx.*
intrinsics, and the compile / run / inspect loop. The chapters build from a
complete scale example through shared-memory and warp-level kernels.
What “native level” means#
A native-level TIRx kernel reads like a structured device kernel: you place threads yourself, allocate shared/per-thread local buffers, write loops and barriers, and call device intrinsics directly. You explicitly choose the orchestration and layouts; standard lowering still dispatches primitives, applies layouts, and vectorizes or unrolls marked loops. This is the foundation the tile primitives (Tile Primitives) are built on; everything here is what those primitives ultimately lower to, so it is also where you go when a hardware feature does not have a primitive yet.
Start here#
If this is your first TIRx kernel, complete First Kernel before using the chapters below as a language reference.