MLIR 23.0.0git
VectorDropLeadUnitDim.cpp File Reference

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "vector-drop-unit-dim"

Functions

static VectorType trimLeadingOneDims (VectorType oldType)
static SmallVector< int64_tsplatZero (int64_t rank)
 Return a smallVector of size rank containing all zeros.
static Value dropLeadingOneDimsFromOperand (OpBuilder &b, Location loc, Value operand, int64_t nDropped)

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "vector-drop-unit-dim"

Definition at line 20 of file VectorDropLeadUnitDim.cpp.

Function Documentation

◆ dropLeadingOneDimsFromOperand()

Value dropLeadingOneDimsFromOperand ( OpBuilder & b,
Location loc,
Value operand,
int64_t nDropped )
static

Definition at line 545 of file VectorDropLeadUnitDim.cpp.

References b, mlir::Value::getType(), and splatZero().

◆ splatZero()

SmallVector< int64_t > splatZero ( int64_t rank)
static

Return a smallVector of size rank containing all zeros.

Definition at line 49 of file VectorDropLeadUnitDim.cpp.

Referenced by dropLeadingOneDimsFromOperand().

◆ trimLeadingOneDims()

VectorType trimLeadingOneDims ( VectorType oldType)
static

Definition at line 27 of file VectorDropLeadUnitDim.cpp.