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
q_tma_prefill
def q_tma_prefill[dtype: DType, //, swizzle_mode: TensorMapSwizzle, *, BM: Int, depth: Int, q_num_heads: Int, num_qk_stages: Int = Int(1)](ctx: DeviceContextBase, ptr: Pointer[Scalar[dtype]], rows: Int) -> TMATensorTile[dtype, _padded_shape[dtype, q_smem_shape_prefill[dtype, swizzle_mode, BM=BM, depth=depth, num_qk_stages=num_qk_stages](), swizzle_mode](), _ragged_shape[dtype, q_smem_shape_prefill[dtype, swizzle_mode, BM=BM, depth=depth, num_qk_stages=num_qk_stages](), swizzle_mode]()]
Creates a split TMA descriptor for a prefill (rank-3) Q tensor tile, pairing the shared-memory tile shape with the global-memory layout.
Args:
- โctx (
DeviceContextBase): Device context used to create the TMA descriptor. - โptr (
Pointer[Scalar[dtype]]): Base pointer to the Q tensor in global memory. - โrows (
Int): Number of rows in the Q tensor exposed via the TMA descriptor.
Returns: