MLIR  16.0.0git
Static Public Member Functions | List of all members
mlir::OpTrait::Vectorizable< ConcreteType > Struct Template Reference

This trait tags Elementwise operatons that can be systematically vectorized. More...

#include "mlir/IR/OpDefinition.h"

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

Static Public Member Functions

static LogicalResult verifyTrait (Operation *op)

Additional Inherited Members

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

Detailed Description

template<typename ConcreteType>
struct mlir::OpTrait::Vectorizable< ConcreteType >

This trait tags Elementwise operatons that can be systematically vectorized.

All scalar operands and results are then replaced by vectors with the respective element type. Semantically, this is the operation on multiple elements simultaneously. See also Tensorizable.

Rationale: Provide the reverse to Scalarizable which, when chained together, allows reasoning about the relationship between the tensor and vector case. Additionally, it permits reasoning about promoting scalars to vectors via broadcasting in cases like select_scalar_pred below.

Definition at line 1403 of file OpDefinition.h.

Member Function Documentation

◆ verifyTrait()

template<typename ConcreteType >
static LogicalResult mlir::OpTrait::Vectorizable< ConcreteType >::verifyTrait ( Operation op)

Definition at line 1404 of file OpDefinition.h.

References mlir::success().

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