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 struct

TMADescriptor

struct TMADescriptor

TMA tensor map descriptor.

An opaque 128-byte descriptor that encodes all parameters for a TMA operation, including tensor dimensions, strides, data type, swizzle mode, and other configuration. This descriptor is created on the host using create_tma_descriptor() and can be passed to device code for use with TMA hardware instructions.

The descriptor must be 64-byte aligned both on the host and device.

Fields​

  • ​data (StaticTuple[UInt8, Int(128)]): The opaque 128-byte descriptor data.

Implemented traits​

AnyType, Copyable, Deinitable, DevicePassable, ImplicitlyCopyable, Movable

comptime members​

device_type​

comptime device_type = TMADescriptor

The device-side type for this TMA descriptor.

Methods​

__init__​

def __init__(out self)

Initializes an empty TMA descriptor.

The descriptor data is uninitialized and must be filled using create_tma_descriptor() before use.

def __init__(out self, *, copy: Self)

Creates a copy of a TMA descriptor.

Args:

  • ​copy (Self): The descriptor to copy.

get_type_name​

static def get_type_name() -> String

Gets the type name for this descriptor.

Returns:

String: The string "TMADescriptor".