Skip to content

TTKernelOp

Nicholas Smith edited this page Jun 24, 2024 · 1 revision

ttkernel.acquire_dst (tt::ttkernel::AcquireDstOp)

Aquire dest call.

Aquire dest operation

ttkernel.add (tt::ttkernel::AddOp)

Add operation

Add operation

Operands:

Operand Description
dst_index 32-bit signless integer

ttkernel.builtin (tt::ttkernel::BuiltinOp)

Builtin call.

Kernel operation

Attributes:

Attribute MLIR Type Description
op ::mlir::FlatSymbolRefAttr flat symbol reference attribute
kind ::mlir::FlatSymbolRefAttr flat symbol reference attribute

Operands:

Operand Description
args variadic of non-0-ranked.memref of any type values or TTKernel cb

ttkernel.cb_pop_front (tt::ttkernel::CBPopFrontOp)

CBPopFront call.

CBPopFront operation

Operands:

Operand Description
cb TTKernel cb

ttkernel.cb_push_back (tt::ttkernel::CBPushBackOp)

CBPushBack call.

CBPushBack operation

Operands:

Operand Description
cb TTKernel cb

ttkernel.cb_reserve_back (tt::ttkernel::CBReserveBackOp)

CBReserveBack call.

CBReserveBack operation

Operands:

Operand Description
cb TTKernel cb

ttkernel.cb_wait_front (tt::ttkernel::CBWaitFrontOp)

CBWaitFront call.

CBWaitFront operation

Operands:

Operand Description
cb TTKernel cb

ttkernel.matmul (tt::ttkernel::MatmulOp)

Matmul operation

Matmul operation

Operands:

Operand Description
dst_index 32-bit signless integer

ttkernel.mul (tt::ttkernel::MulOp)

Mul operation

Mul operation

Operands:

Operand Description
dst_index 32-bit signless integer

ttkernel.pack (tt::ttkernel::PackOp)

Pack op.

Pack operation

Operands:

Operand Description
dst_index 32-bit signless integer
out_cb TTKernel cb
out_index 32-bit signless integer

ttkernel.pack_set_data_type (tt::ttkernel::PackSetDataTypeOp)

Pack set DataType op.

Pack set DataType operation

Attributes:

Attribute MLIR Type Description
data_type ::mlir::tt::DataTypeAttr
TT DataTypes{{% markdown %}}Enum cases: * f32 (`Float32`) * f16 (`Float16`) * bf16 (`BFloat16`) * bc_f8 (`BC_Float8`) * bc_bf8 (`BC_BFloat8`) * bc_f4 (`BC_Float4`) * bc_bf4 (`BC_BFloat4`) * bc_f2 (`BC_Float2`) * bc_bf2 (`BC_BFloat2`) * u32 (`UInt32`) * u16 (`UInt16`) * u8 (`UInt8`){{% /markdown %}}

ttkernel.release_dst (tt::ttkernel::ReleaseDstOp)

Release dest call.

Release dest operation

ttkernel.return (tt::ttkernel::ReturnOp)

Return op.

Return operation

Traits: AlwaysSpeculatableImplTrait, ReturnLike, Terminator

Interfaces: ConditionallySpeculatable, NoMemoryEffect (MemoryEffectOpInterface), RegionBranchTerminatorOpInterface

Effects: MemoryEffects::Effect{}

ttkernel.sub (tt::ttkernel::SubOp)

Sub operation

Sub operation

Operands:

Operand Description
dst_index 32-bit signless integer

ttkernel.unpack_ab (tt::ttkernel::UnpackABOp)

UnpackAB op.

UnpackAB operation

Operands:

Operand Description
cb_a TTKernel cb
src_a_index 32-bit signless integer
cb_b TTKernel cb
src_b_index 32-bit signless integer

ttkernel.unpack_a (tt::ttkernel::UnpackAOp)

UnpackA op.

UnpackA operation

Operands:

Operand Description
cb TTKernel cb
src_index 32-bit signless integer

ttkernel.unpack_set_data_type (tt::ttkernel::UnpackSetDataTypeOp)

Unpack set DataType op.

Unpack set DataType operation

Attributes:

Attribute MLIR Type Description
data_type_a ::mlir::tt::DataTypeAttr
TT DataTypes{{% markdown %}}Enum cases: * f32 (`Float32`) * f16 (`Float16`) * bf16 (`BFloat16`) * bc_f8 (`BC_Float8`) * bc_bf8 (`BC_BFloat8`) * bc_f4 (`BC_Float4`) * bc_bf4 (`BC_BFloat4`) * bc_f2 (`BC_Float2`) * bc_bf2 (`BC_BFloat2`) * u32 (`UInt32`) * u16 (`UInt16`) * u8 (`UInt8`){{% /markdown %}}
data_type_b ::mlir::tt::DataTypeAttr
TT DataTypes{{% markdown %}}Enum cases: * f32 (`Float32`) * f16 (`Float16`) * bf16 (`BFloat16`) * bc_f8 (`BC_Float8`) * bc_bf8 (`BC_BFloat8`) * bc_f4 (`BC_Float4`) * bc_bf4 (`BC_BFloat4`) * bc_f2 (`BC_Float2`) * bc_bf2 (`BC_BFloat2`) * u32 (`UInt32`) * u16 (`UInt16`) * u8 (`UInt8`){{% /markdown %}}

ttkernel.unreachable (tt::ttkernel::UnreachableOp)

Unreachable op.

Unreachable operation

Traits: AlwaysSpeculatableImplTrait, ReturnLike, Terminator

Interfaces: ConditionallySpeculatable, NoMemoryEffect (MemoryEffectOpInterface), RegionBranchTerminatorOpInterface

Effects: MemoryEffects::Effect{}