triton.experimental.gluon.language.amd.cdna3.buffer.atomic_load
- triton.experimental.gluon.language.amd.cdna3.buffer.atomic_load(desc, offsets, mask=None, sem=None, scope=None, *, soffset=None, _semantic=None)
Atomically load from global memory through a buffer descriptor.
The buffer counterpart of
atomic_load(): each element is loaded atomically and the load is never removed, merged or hoisted, so it can poll a flag written by another program. Elementiis read frombase + soffset + offsets[i]; masked-off and out-of-bounds elements read zero. Seemake_buffer_descriptor()for the bounds.- Parameters:
desc (buffer_descriptor) – Descriptor of the global memory to load from.
offsets (tensor) – Offsets of the elements to load, in elements.
mask (tensor, optional) – Mask tensor for predicated loads. Defaults to None.
sem (str, optional) –
"acquire"or"relaxed". Defaults to"acquire".scope (str, optional) –
"cta","gpu"or"sys". Defaults to"gpu".soffset (int32 scalar or tensor, optional) – Offset, in elements, added to every element’s offset and counted by the bounds check. It is held in the instruction’s scalar offset register, so a uniform advance costs no per-lane arithmetic. A tensor gives each wave its own value: it broadcasts to
offsetsand must have size 1 in every dimension the lanes of the offsets’ layout span, e.g. shape[M, 1]for[M, N]offsets whose rows each sit in one wave. Defaults to None (0).
- Returns:
The loaded values, with the shape and layout of
offsets.- Return type: