Skip to main content

Mojo struct

NullTrace

struct NullTrace

Zero-sized no-op trace buffer. store is pass; struct has no fields so it contributes 0 kernel-arg bytes when passed as an argument.

Implemented traits

AnyType, Copyable, DevicePassable, ImplicitlyCopyable, ImplicitlyDestructible, Movable, RegisterPassable, TraceBuf, TrivialRegisterPassable

comptime members

device_type

comptime device_type = NullTrace

Device-side type alias. NullTrace is trivially device-passable.

Methods

__init__

__init__() -> Self

Constructs a zero-sized no-op trace buffer.

store

store(self, offset: Int, val: UInt64)

No-op store. The body compiles away entirely.

Args:

  • offset (Int): Unused.
  • val (UInt64): Unused.

get_type_name

static get_type_name() -> String

Returns the type name for runtime diagnostics.

Returns:

String: Always "NullTrace".

Was this page helpful?