IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /get-started.md). For the complete documentation index, see llms.txt.
Skip to main content
For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /get-started.md).

Mojo function

scale_align_elems

def scale_align_elems[dtype: DType]() -> Int

Scales per 16-byte unit, and so the granularity a flat scale TMA may START a copy at.

A TMA's global start address must be 16-byte aligned. In a flat 1 x N scale view a key index IS the innermost coordinate, so that requirement lands on the key index itself -- unlike a K tile, whose row is a whole depth-wide key and is therefore always aligned.

Parameters:

  • ​dtype (DType): Scale element type.

Returns:

Int: Number of scales per 16-byte unit.

Was this page helpful?