MLIR
22.0.0git
|
#include "mlir/Conversion/AffineToStandard/AffineToStandard.h"
#include "mlir/Dialect/Affine/IR/AffineOps.h"
#include "mlir/Dialect/Affine/Transforms/Transforms.h"
#include "mlir/Dialect/Affine/Utils.h"
#include "mlir/Dialect/MemRef/IR/MemRef.h"
#include "mlir/Dialect/SCF/IR/SCF.h"
#include "mlir/Dialect/Vector/IR/VectorOps.h"
#include "mlir/IR/IntegerSet.h"
#include "mlir/IR/MLIRContext.h"
#include "mlir/Transforms/DialectConversion.h"
#include "mlir/Transforms/Passes.h"
#include "mlir/Conversion/Passes.h.inc"
Go to the source code of this file.
Namespaces | |
mlir | |
Include the generated interface declarations. | |
Macros | |
#define | GEN_PASS_DEF_LOWERAFFINEPASS |
Functions | |
static Value | buildMinMaxReductionSeq (Location loc, arith::CmpIPredicate predicate, ValueRange values, OpBuilder &builder) |
Given a range of values, emit the code that reduces them with "min" or "max" depending on the provided comparison predicate, sgt for max and slt for min. More... | |
static Value | lowerAffineMapMax (OpBuilder &builder, Location loc, AffineMap map, ValueRange operands) |
Emit instructions that correspond to computing the maximum value among the values of a (potentially) multi-output affine map applied to operands . More... | |
static Value | lowerAffineMapMin (OpBuilder &builder, Location loc, AffineMap map, ValueRange operands) |
Emit instructions that correspond to computing the minimum value among the values of a (potentially) multi-output affine map applied to operands . More... | |
#define GEN_PASS_DEF_LOWERAFFINEPASS |
Definition at line 28 of file AffineToStandard.cpp.
|
static |
Given a range of values, emit the code that reduces them with "min" or "max" depending on the provided comparison predicate, sgt for max and slt for min.
Multiple values are scanned in a linear sequence. This creates a data dependences that wouldn't exist in a tree reduction, but is easier to recognize as a reduction by the subsequent passes.
Definition at line 42 of file AffineToStandard.cpp.
Referenced by lowerAffineMapMax(), and lowerAffineMapMin().
|
static |
Emit instructions that correspond to computing the maximum value among the values of a (potentially) multi-output affine map applied to operands
.
Definition at line 63 of file AffineToStandard.cpp.
References buildMinMaxReductionSeq(), and mlir::affine::expandAffineMap().
|
static |
Emit instructions that correspond to computing the minimum value among the values of a (potentially) multi-output affine map applied to operands
.
Definition at line 73 of file AffineToStandard.cpp.
References buildMinMaxReductionSeq(), and mlir::affine::expandAffineMap().