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

Mojo function

cp_async_bulk_tensor_global_shared_cta_elect

def cp_async_bulk_tensor_global_shared_cta_elect[src_type: AnyType, rank: Int, /, eviction_policy: CacheEviction = CacheEviction.EVICT_NORMAL](src_mem: Pointer[src_type, address_space=AddressSpace.SHARED], tma_descriptor: Pointer[NoneType], coords: IndexList[rank], elect: Int32)

Elect-predicated variant of cp_async_bulk_tensor_global_shared_cta.

Behaves exactly like cp_async_bulk_tensor_global_shared_cta except that the TMA store is guarded by a PTX predicate derived from elect: the instruction is issued only when elect != 0. All lanes follow the same PTX control flow, so there is no Mojo-level branch and no warp-divergent if elect != 0: wrapper at the call site.

Parameters:

  • ​src_type (AnyType): The data type of the source tensor elements.
  • ​rank (Int): The dimensionality of the tensor (1, 2, 3, 4, or 5).
  • ​eviction_policy (CacheEviction): Optional cache eviction policy. Defaults to EVICT_NORMAL.

Args:

Was this page helpful?