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

LoadOrderBarrierStorage

struct LoadOrderBarrierStorage

Storage for load order barrier (mainloop β†’ epilogue load coordination).

This single barrier coordinates the mainloop load warp with the epilogue load warp, ensuring the epilogue load doesn't start before the mainloop has issued its prologue TMA operations.

Protocol:

  1. Mainloop load warp issues prologue loads
  2. Mainloop load warp calls arrive() on this barrier
  3. Epilogue load warp waits on this barrier before starting

This prevents TMA resource contention between mainloop and epilogue loads.

Fields​

  • ​barrier_storage (LoadOrderBarrierStorage.BarrierArray.Storage):

Implemented traits​

AnyType, ImplicitlyDestructible

comptime members​

BarrierArray​

comptime BarrierArray = SMemArray[SharedMemBarrier, 1]

Methods​

barrier​

barrier(ref[AddressSpace._value] self) -> LoadOrderBarrierStorage.BarrierArray

Get the load order barrier.

Returns:

LoadOrderBarrierStorage.BarrierArray

ptr​

ptr(ref[AddressSpace._value] self) -> MbarPtr

Get raw barrier pointer for initialization.

Returns:

MbarPtr