MLIR 22.0.0git
PatternLoggingListener.cpp
Go to the documentation of this file.
2#include "llvm/Support/DebugLog.h"
3
4#define DEBUG_TYPE "pattern-logging-listener"
5
6using namespace mlir;
7
9 Operation *op, InsertPoint previous) {
10 LDBG() << patternName << " | notifyOperationInserted"
11 << " | " << op->getName();
13}
14
16 Operation *op) {
17 LDBG() << patternName << " | notifyOperationModified"
18 << " | " << op->getName();
20}
21
23 Operation *op, Operation *newOp) {
24 LDBG() << patternName << " | notifyOperationReplaced (with op)"
25 << " | " << op->getName() << " | " << newOp->getName();
27}
28
31 LDBG() << patternName << " | notifyOperationReplaced (with values)"
32 << " | " << op->getName();
34}
35
37 Operation *op) {
38 LDBG() << patternName << " | notifyOperationErased"
39 << " | " << op->getName();
41}
42
44 const Pattern &pattern, Operation *op) {
45 LDBG() << patternName << " | notifyPatternBegin"
46 << " | " << op->getName();
48}
*if copies could not be generated due to yet unimplemented cases *copyInPlacementStart and copyOutPlacementStart in copyPlacementBlock *specify the insertion points where the incoming copies and outgoing should be the output argument nBegin is set to its * replacement(set to `begin` if no invalidation happens). Since outgoing *copies could have been inserted at `end`
This class represents a saved insertion point.
Definition Builders.h:327
Operation is the basic unit of execution within MLIR.
Definition Operation.h:88
OperationName getName()
The name of an operation is the key identifier for it.
Definition Operation.h:119
This class contains all of the data related to a pattern, but does not contain any methods or logic f...
This class provides an abstraction over the different types of ranges over Values.
Definition ValueRange.h:387
Include the generated interface declarations.
void notifyOperationInserted(Operation *op, InsertPoint previous) override
Notify the listener that the specified operation was inserted.
void notifyOperationModified(Operation *op) override
Notify the listener that the specified operation was modified in-place.
void notifyPatternBegin(const Pattern &pattern, Operation *op) override
Notify the listener that the specified pattern is about to be applied at the specified root operation...
void notifyOperationReplaced(Operation *op, Operation *newOp) override
Notify the listener that all uses of the specified operation's results are about to be replaced with ...
void notifyOperationErased(Operation *op) override
Notify the listener that the specified operation is about to be erased.
void notifyOperationModified(Operation *op) override
Notify the listener that the specified operation was modified in-place.
void notifyOperationErased(Operation *op) override
Notify the listener that the specified operation is about to be erased.
void notifyOperationReplaced(Operation *op, Operation *newOp) override
Notify the listener that all uses of the specified operation's results are about to be replaced with ...
void notifyOperationInserted(Operation *op, InsertPoint previous) override
Notify the listener that the specified operation was inserted.
void notifyPatternBegin(const Pattern &pattern, Operation *op) override
Notify the listener that the specified pattern is about to be applied at the specified root operation...