13 #ifndef CIRCT_TRANSFORMS_PASSES_H
14 #define CIRCT_TRANSFORMS_PASSES_H
17 #include "mlir/Dialect/Affine/IR/AffineOps.h"
18 #include "mlir/IR/BuiltinOps.h"
19 #include "mlir/Pass/Pass.h"
37 #include "circt/Transforms/Passes.h.inc"
43 const std::function<
bool(mlir::Location)> &pred);
47 std::unique_ptr<mlir::Pass>
89 LogicalResult
maximizeSSA(Value value, PatternRewriter &rewriter);
98 PatternRewriter &rewriter);
108 PatternRewriter &rewriter);
117 PatternRewriter &rewriter);
124 mlir::ConversionPatternRewriter &rewriter);
131 #define GEN_PASS_REGISTRATION
132 #include "circt/Transforms/Passes.h.inc"
Strategy class to control the behavior of SSA maximization.
virtual bool maximizeResult(OpResult res)
Determines whether an operation's result should be SSA maximized.
virtual ~SSAMaximizationStrategy()=default
virtual bool maximizeArgument(BlockArgument arg)
Determines whether a block argument should be SSA maximized.
virtual bool maximizeBlock(Block *block)
Determines whether a block should have the values it defines (i.e., block arguments and operation res...
virtual bool maximizeOp(Operation *op)
Determines whether an operation should have its results SSA maximized.
The InstanceGraph op interface, see InstanceGraphInterface.td for more details.
std::unique_ptr< mlir::Pass > createMaximizeSSAPass()
std::unique_ptr< mlir::Pass > createPrintOpCountPass()
std::unique_ptr< mlir::Pass > createMemoryBankingPass(std::optional< unsigned > bankingFactor=std::nullopt)
std::unique_ptr< mlir::Pass > createInsertMergeBlocksPass()
std::unique_ptr< mlir::Pass > createIndexSwitchToIfPass()
std::unique_ptr< mlir::Pass > createMapArithToCombPass()
mlir::LogicalResult insertMergeBlocks(mlir::Region &r, mlir::ConversionPatternRewriter &rewriter)
Insert additional blocks that serve as counterparts to the blocks that diverged the control flow.
LogicalResult maximizeSSA(Value value, PatternRewriter &rewriter)
Converts a single value within a function into maximal SSA form.
std::unique_ptr< mlir::Pass > createFlattenMemRefPass()
bool isUniDimensional(mlir::MemRefType memref)
bool isRegionSSAMaximized(Region ®ion)
std::unique_ptr< mlir::Pass > createFlattenMemRefCallsPass()
std::unique_ptr< mlir::Pass > createStripDebugInfoWithPredPass(const std::function< bool(mlir::Location)> &pred)
Creates a pass to strip debug information from a function.