triton.experimental.gluon.language.NVMMASharedLayout

class triton.experimental.gluon.language.NVMMASharedLayout(self, swizzle_byte_width: int, element_bitwidth: int, rank: int = 2, transposed: bool = False, fp4_padded: bool = False, cga_layout: List[List[int]] = <factory>)

Represents a layout for shared memory suitable for NVIDIA MMA operations.

Parameters:
  • swizzle_byte_width (int) – Width in bytes for swizzling.

  • element_bitwidth (int) – Bitwidth of element type.

  • rank (int) – Rank of the tensor.

  • transposed (bool) – Whether the layout is transposed.

  • fp4_padded (bool) – Whether FP4 padding is used.

  • cga_layout (Optional[List[List[int]]]) – Bases describing CTA tiling.

__init__(self, swizzle_byte_width: int, element_bitwidth: int, rank: int = 2, transposed: bool = False, fp4_padded: bool = False, cga_layout: List[List[int]] = <factory>) None

Methods

__init__(self, swizzle_byte_width, ...)

format_hardware_view(self, shape)

format_tensor_view(self, shape)

mangle(self)

Attributes

fp4_padded

get_default_for

Returns an NVMMASharedLayout with default swizzling for a given shape.

rank

transposed

type

swizzle_byte_width

element_bitwidth

cga_layout