Skip to main content

Crate cubecl_tile

Crate cubecl_tile 

Source
Expand description

The axis-agnostic tile DSL engine: a Space cut into Levels forms a Partitioning, whose loops hand out Regions; the Launcher reads the grid off the same levels.

Modules§

dialect
The tile ops in the IR, each lowered by every backend’s LowerOpsPass.
kind
What a Tile can be in the kernel.
launch
Binding tensors to a kernel and launching it: the Launcher, each operand’s comptime spec, the binding that builds it from a tensor, the args the kernel receives, and the Vectorization that settles each operand’s width.
layout
Where an operand’s axes live: Projection maps logical axes onto buffer dims (projection), storage says how the values lie in memory, paging reads a pool of pages as sequences, a compaction boxes a gathered sub-tile, and a row_arrangement places a stage’s lines.
ops
The verbs a client runs over tiles: matmul (mma), product, reduce and softmax.
procedural
Tiles whose values are computed from their coordinates.
space
The logical coordinate space a tile lives in, and how a level of it splits (partition).
stage
Staging an operand: storage, transports, pipelined slots and the barriers between fill and read.

Structs§

Axis
A labeled axis. The u8 is a client-assigned index, not a position.
AxisSlices
A tile cut into slices along axis, one for every index of its other axes, each read and written whole where the tile’s holder keeps it: the verbs an op reducing or broadcasting along one axis runs. The slices write through to the tile.
AxisSlicesExpand
Factor
The scale a tile carries: none, or a scale tile, itself under its own scale or none. What Tile::factor takes out of a tile and Tile::scaled puts on one.
FactorExpand
Geometry
One operand’s physical (extent, stride) per dim, in scalars, and its storage tiling.
Launcher
One launch: a kernel-form partitioning, the concrete space with real extents, and the grid. What it settled is shared, so a launch kept and run again clones it for the price of a count.
Leaves
The regions at a partitioning’s innermost level below one region (Region::leaves).
Level
One decomposition level of a space: who takes its tiles and how it cuts each axis it names. Unnamed axes are handed down whole.
Levels
A partitioning stated from the leaf up.
Partitioning
A space with the levels that partition it, outermost first: what a kernel’s loops iterate.
Planes
The planes below one region, each once (Region::planes).
Projection
An operand’s logical axes mapped onto its buffer’s physical axes.
Region
The path a kernel’s loops took to a box, with the coordinates each loop handed out. Iterating distributes the next level.
RegisterBlock
Execution and unrolling configuration for the software instruction.
Semiring
A product monoid and the accumulation monoid its products sum into.
Space
Every axis with its extent, in canonical order, plus the runtime sizes of dynamic axes.
Stages
The depth slots of one buffered walk and the operands they are filled from.
Tile
One operand’s data: a runtime backing store and the comptime Space it projects.
TileArg
An operand as a single launch argument: its values, a buffer or a TMA tensor map, its comptime TileSpec, the element its buffer holds, and the scales they are read under.
TileArgLaunch
The host side of a TileArg: its values, its spec, the element its buffer holds and its scales. The spec is shared: a rebound operand and the compilation argument it registers as read the one its launch was settled with.
TileExpand
TileSpec
The comptime half of an operand: its axis mapping, edge checks, packing, storage and delivery.
Walk
The runtime odometer over a Space’s tiles under one Level.

Enums§

Indexing
What an operand’s table entry places. The table’s own dims are its keys (TileArgLaunch::indexed).
Instruction
What one plane contracts through: a software register block or a hardware fragment form.
MmaOperands
What a manual-mma instruction’s operands are: the blueprint’s choice, which every leaf reads, so the operands a leaf is handed never decide it.
Monoid
An identity and an associative operation, used by everything that merges values.
Scratch
How much of a plane’s accumulator its scratch holds at once. Serialized names are persisted in autotune keys and must not change.
StageStorage
Where a stage lives and how it lays its cells out, stated at Stages::smem.

Traits§

Carrier
The ordering and arithmetic a Monoid needs of the values it combines.