pub fn from_rows_gather(
spec: &RowsGatherSpec,
names: &StageNames,
float: bool,
dense: bool,
target: &SpatialTarget,
) -> Result<SpatialProgram, SpatialReject>Expand description
X = rows I of T — the block gather: row k of X is row I[k] (1-based) of a flat rows·cols table, for every
index of I at once, in ONE section; X is written as flat rows (the layout pass bridges it once where the program
lays X out as a matrix).
★ EVERY INDEX IS DATA, CHECKED WHERE IT IS READ: taken less one and read through a guard of stride zero against the
table’s rows, so an index outside the table faults where every tier’s check fails instead of reading another row.
· Rows of WHOLE TILES (a real embedding table): item (k, b) moves row k‘s b-th blk-tile block. It reads its
own index — element k of I, k taken from a compile-time table holding it in tile k — and loads the row’s
block through an IndirectTile over the guarded I[k] − 1, so exactly the gathered rows’ tiles move.
· Rows narrower than a tile: one item gathers the block from the table held whole — one band of the output per
row, each reading the table at its row’s offset (I[k] − 1)·cols — refused by name when the table or the block
is wider than a site’s page.