'tensor_ext' Dialect
An tensor extension out-of-tree MLIR dialect
This dialect contains dedicated operations, types, and attributes designed for extending the in-tree tensor dialect in MLIR.
Operations¶
tensor_ext.chunk (streamtensor::tensor_ext::ChunkOp)¶
Chunk a tensor to multiple tensors
Syntax:
operation ::= `tensor_ext.chunk` `dim` `(` $dim `)` $source `to` $size attr-dict `:`
              functional-type(operands, results)
Traits: AlwaysSpeculatableImplTrait
Interfaces: ConditionallySpeculatable, NoMemoryEffect (MemoryEffectOpInterface)
Effects: MemoryEffects::Effect{}
Attributes:¶
| Attribute | MLIR Type | Description | 
|---|---|---|
dim | ::mlir::IntegerAttr | 64-bit signed integer attribute | 
size | ::mlir::IntegerAttr | 64-bit signed integer attribute | 
Operands:¶
| Operand | Description | 
|---|---|
source | 
ranked tensor of any type values | 
Results:¶
| Result | Description | 
|---|---|
results | 
variadic of ranked tensor of any type values | 
tensor_ext.instance (streamtensor::tensor_ext::InstanceOp)¶
A tensor instance that is not pure
Syntax:
operation ::= `tensor_ext.instance` attr-dict `:` type(results)
Results:¶
| Result | Description | 
|---|---|
result | 
ranked tensor of any type values | 
tensor_ext.unwiden (streamtensor::tensor_ext::UnWidenOp)¶
Unwiden a tensor to scalar type
Syntax:
operation ::= `tensor_ext.unwiden` $source attr-dict `:` functional-type(operands, results)
Traits: AlwaysSpeculatableImplTrait
Interfaces: ConditionallySpeculatable, NoMemoryEffect (MemoryEffectOpInterface), TensorViewLikeOpInterface
Effects: MemoryEffects::Effect{}
Operands:¶
| Operand | Description | 
|---|---|
source | 
ranked tensor of vector of any type values values | 
Results:¶
| Result | Description | 
|---|---|
result | 
ranked tensor of any type values | 
tensor_ext.widen (streamtensor::tensor_ext::WidenOp)¶
Widen a tensor to vector element
Syntax:
operation ::= `tensor_ext.widen` $source attr-dict `:` functional-type(operands, results)
Traits: AlwaysSpeculatableImplTrait
Interfaces: ConditionallySpeculatable, NoMemoryEffect (MemoryEffectOpInterface), TensorViewLikeOpInterface
Effects: MemoryEffects::Effect{}
Operands:¶
| Operand | Description | 
|---|---|
source | 
ranked tensor of any type values | 
Results:¶
| Result | Description | 
|---|---|
result | 
ranked tensor of vector of any type values values | 
Attributes¶
VectorizationEncodingAttr¶
Vectorization encoding of a tensor
Syntax:
#tensor_ext.vector<
  ::llvm::ArrayRef<int64_t>   # shape
>
Parameters:¶
| Parameter | C++ type | Description | 
|---|---|---|
| shape | ::llvm::ArrayRef<int64_t> |