MLIR: lib/Dialect/SparseTensor/Transforms/Utils/LoopEmitter.cpp File Reference (original) (raw)

Go to the source code of this file.

Macros
#define CMPI(p, l, r)
#define C_IDX(v) (constantIndex(builder, loc, (v)))
#define YIELD(vs) (builder.createscf::YieldOp(loc, (vs)))
#define ADDI(lhs, rhs) (builder.createarith::AddIOp(loc, (lhs), (rhs)))
#define ANDI(lhs, rhs) (builder.createarith::AndIOp(loc, (lhs), (rhs)))
#define SUBI(lhs, rhs) (builder.createarith::SubIOp(loc, (lhs), (rhs)))
#define MULI(lhs, rhs) (builder.createarith::MulIOp(loc, (lhs), (rhs)))
#define REMUI(lhs, rhs) (builder.createarith::RemUIOp(loc, (lhs), (rhs)))
#define DIVUI(lhs, rhs) (builder.createarith::DivUIOp(loc, (lhs), (rhs)))
#define SELECT(c, l, r) (builder.createarith::SelectOp(loc, (c), (l), (r)))
Functions
static LLVM_ATTRIBUTE_UNUSED void dumpIndexMemRef (OpBuilder &builder, Location loc, Value memref)
static Value genSliceOffset (OpBuilder &builder, Location loc, Value tensor, Level lvl)
static Value genSliceStride (OpBuilder &builder, Location loc, Value tensor, Level lvl)
static bool isIntOrFPZero (Attribute attr)
static Value unFoldOpIntResult (OpBuilder &builder, Location loc, OpFoldResult ofr)
static Value tryFoldTensors (Value t)

ADDI

| #define ADDI | ( | | lhs, | | ------------ | -------------------------------------------------- | | ---- | | | rhs | | | | | ) | (builder.createarith::AddIOp(loc, (lhs), (rhs))) | | |

ANDI

| #define ANDI | ( | | lhs, | | ------------ | -------------------------------------------------- | | ---- | | | rhs | | | | | ) | (builder.createarith::AndIOp(loc, (lhs), (rhs))) | | |

C_IDX

| #define C_IDX | ( | | v | ) | (constantIndex(builder, loc, (v))) | | -------------- | - | | - | - | ---------------------------------- |

CMPI

Value:

(builder.createarith::CmpIOp(loc, arith::CmpIPredicate::p, (l), (r)) \

.getResult())

Definition at line 29 of file LoopEmitter.cpp.

DIVUI

| #define DIVUI | ( | | lhs, | | ------------- | --------------------------------------------------- | | ---- | | | rhs | | | | | ) | (builder.createarith::DivUIOp(loc, (lhs), (rhs))) | | |

MULI

| #define MULI | ( | | lhs, | | ------------ | -------------------------------------------------- | | ---- | | | rhs | | | | | ) | (builder.createarith::MulIOp(loc, (lhs), (rhs))) | | |

REMUI

| #define REMUI | ( | | lhs, | | ------------- | --------------------------------------------------- | | ---- | | | rhs | | | | | ) | (builder.createarith::RemUIOp(loc, (lhs), (rhs))) | | |

SELECT

| #define SELECT | ( | | c, | | -------------- | ----------------------------------------------------- | | -- | | | l, | | | | | | r | | | | | ) | (builder.createarith::SelectOp(loc, (c), (l), (r))) | | |

SUBI

| #define SUBI | ( | | lhs, | | ------------ | -------------------------------------------------- | | ---- | | | rhs | | | | | ) | (builder.createarith::SubIOp(loc, (lhs), (rhs))) | | |

YIELD

| #define YIELD | ( | | vs | ) | (builder.createscf::YieldOp(loc, (vs))) | | ------------- | - | | -- | - | ----------------------------------------- |

dumpIndexMemRef()

genSliceOffset()

genSliceStride()

isIntOrFPZero()

static bool isIntOrFPZero ( Attribute attr) static

tryFoldTensors()

unFoldOpIntResult()