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 struct

FourWaveOps

struct FourWaveOps

Op tags for the 4-wave matmul kernel.

Fields​

  • ​value (Int): Integer tag identifying the op kind.

Implemented traits​

AnyType, Equatable, ImplicitlyDeletable, ScheduleOps

comptime members​

BARRIER​

comptime BARRIER = FourWaveOps(128)

Workgroup-wide barrier (e.g. s_barrier on AMD).

COMPUTE​

comptime COMPUTE = FourWaveOps(2)

Generic compute op (unused by 4-wave; reserved tag).

LOAD_A​

comptime LOAD_A = FourWaveOps(0)

DRAM->LDS prefetch of an A sub-tile.

LOAD_B​

comptime LOAD_B = FourWaveOps(1)

DRAM->LDS prefetch of a B sub-tile.

MMA​

comptime MMA = FourWaveOps(5)

MFMA quadrant compute op.

MMA_LOAD_A​

comptime MMA_LOAD_A = FourWaveOps(3)

LDS->register fragment load of an A quadrant.

MMA_LOAD_B​

comptime MMA_LOAD_B = FourWaveOps(4)

LDS->register fragment load of a B quadrant.

NONE​

comptime NONE = FourWaveOps(255)

Sentinel value for an absent or unspecified op.

SCHED_GROUP_BARRIER​

comptime SCHED_GROUP_BARRIER = FourWaveOps(133)

LLVM scheduling-group barrier hint (s_sched_group_barrier).

SCHEDULE_BARRIER​

comptime SCHEDULE_BARRIER = FourWaveOps(132)

LLVM scheduling-barrier hint (schedule_barrier).

SET_PRIO​

comptime SET_PRIO = FourWaveOps(131)

Wave priority hint (e.g. s_setprio).

WAIT_LGKM​

comptime WAIT_LGKM = FourWaveOps(130)

Wait on outstanding LDS / scalar-memory ops (e.g. s_waitcnt lgkmcnt).

WAIT_VM​

comptime WAIT_VM = FourWaveOps(129)

Wait on outstanding global-memory loads (e.g. s_waitcnt vmcnt).