IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /max/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. /max/get-started.md).

Mojo function

packA_i8mm

def packA_i8mm[a_type: DType](t0: Int, t1: Int, k: Int, a_ptr: Pointer[Scalar[a_type], address_space=a_ptr.address_space, _safe=False], a_packed_ptr: Pointer[Scalar[a_type], address_space=a_packed_ptr.address_space, _safe=False])

Packs a range of rows of matrix A for the i8mm kernel layout.

Parameters:

  • ​a_type (DType): The dtype of the A tensor.

Args:

  • ​t0 (Int): The starting row index of the range to pack.
  • ​t1 (Int): The ending row index of the range to pack (exclusive).
  • ​k (Int): The K dimension of the matmul.
  • ​a_ptr (Pointer[Scalar[a_type], address_space=a_ptr.address_space, _safe=False]): Pointer to the source A matrix in row-major layout.
  • ​a_packed_ptr (Pointer[Scalar[a_type], address_space=a_packed_ptr.address_space, _safe=False]): Pointer to the destination packed A buffer.

Was this page helpful?