MLIR  17.0.0git
Static Public Member Functions | List of all members
mlir::OpTrait::InferTensorType< ConcreteType > Class Template Reference

Tensor type inference trait that constructs a tensor from the inferred shape and elemental types. More...

#include "mlir/Interfaces/InferTypeOpInterface.h"

+ Inheritance diagram for mlir::OpTrait::InferTensorType< ConcreteType >:
+ Collaboration diagram for mlir::OpTrait::InferTensorType< ConcreteType >:

Static Public Member Functions

static LogicalResult inferReturnTypes (MLIRContext *context, std::optional< Location > location, ValueRange operands, DictionaryAttr attributes, RegionRange regions, SmallVectorImpl< Type > &inferredReturnTypes)
 

Additional Inherited Members

- Protected Member Functions inherited from mlir::OpTrait::TraitBase< ConcreteType, InferTensorType >
OperationgetOperation ()
 Return the ultimate Operation being worked on. More...
 

Detailed Description

template<typename ConcreteType>
class mlir::OpTrait::InferTensorType< ConcreteType >

Tensor type inference trait that constructs a tensor from the inferred shape and elemental types.

Requires: Op implements InferShapedTypeOpInterface and InferTypeOpInterface. Less strict is possible (e.g., implements inferReturnTypeComponents and these always populates all element types and shapes or fails, but this\ trait is currently only used where the interfaces are, so keep it restricted for now).

Definition at line 279 of file InferTypeOpInterface.h.

Member Function Documentation

◆ inferReturnTypes()

template<typename ConcreteType >
static LogicalResult mlir::OpTrait::InferTensorType< ConcreteType >::inferReturnTypes ( MLIRContext context,
std::optional< Location location,
ValueRange  operands,
DictionaryAttr  attributes,
RegionRange  regions,
SmallVectorImpl< Type > &  inferredReturnTypes 
)
inlinestatic

Definition at line 282 of file InferTypeOpInterface.h.

References mlir::detail::inferReturnTensorTypes().


The documentation for this class was generated from the following file: