MLIR  17.0.0git
Classes | Namespaces | Enumerations | Functions
GreedyPatternRewriteDriver.h File Reference
#include "mlir/Rewrite/FrozenRewritePatternSet.h"
+ Include dependency graph for GreedyPatternRewriteDriver.h:

Go to the source code of this file.

Classes

class  mlir::GreedyRewriteConfig
 This class allows control over how the GreedyPatternRewriteDriver works. More...
 

Namespaces

 mlir
 Include the generated interface declarations.
 

Enumerations

enum class  mlir::GreedyRewriteStrictness { mlir::AnyOp , mlir::ExistingAndNewOps , mlir::ExistingOps }
 This enum controls which ops are put on the worklist during a greedy pattern rewrite. More...
 

Functions

LogicalResult mlir::applyPatternsAndFoldGreedily (Region &region, const FrozenRewritePatternSet &patterns, GreedyRewriteConfig config=GreedyRewriteConfig())
 Rewrite ops in the given region, which must be isolated from above, by repeatedly applying the highest benefit patterns in a greedy work-list driven manner. More...
 
LogicalResult mlir::applyPatternsAndFoldGreedily (Operation *op, const FrozenRewritePatternSet &patterns, GreedyRewriteConfig config=GreedyRewriteConfig())
 Rewrite ops in all regions of the given op, which must be isolated from above. More...
 
LogicalResult mlir::applyOpPatternsAndFold (ArrayRef< Operation * > ops, const FrozenRewritePatternSet &patterns, GreedyRewriteStrictness strictMode, bool *changed=nullptr, bool *allErased=nullptr, Region *scope=nullptr)
 Applies the specified rewrite patterns on ops while also trying to fold these ops. More...
 
LogicalResult mlir::applyOpPatternsAndFold (Operation *op, const FrozenRewritePatternSet &patterns, bool *erased=nullptr)
 Applies the specified patterns on op alone while also trying to fold it, by selecting the highest benefits patterns in a greedy manner. More...