File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change
1
+ // RUN: mlir-opt %s --test-walk-pattern-rewrite-driver \
2
+ // RUN: --allow-unregistered-dialect --debug-only=pattern-logging-listener 2>&1 | FileCheck %s
3
+
4
+ // Check that when replacing an op with a new op, we get appropriate
5
+ // pattern-logging lines
6
+ // CHECK: [pattern-logging-listener] (anonymous namespace)::ReplaceWithNewOp | notifyOperationInserted | test.new_op
7
+ // CHECK: [pattern-logging-listener] (anonymous namespace)::ReplaceWithNewOp | notifyOperationReplaced (with values) | test.replace_with_new_op
8
+ // CHECK: [pattern-logging-listener] (anonymous namespace)::ReplaceWithNewOp | notifyOperationModified | arith.addi
9
+ // CHECK: [pattern-logging-listener] (anonymous namespace)::ReplaceWithNewOp | notifyOperationModified | arith.addi
10
+ // CHECK: [pattern-logging-listener] (anonymous namespace)::ReplaceWithNewOp | notifyOperationErased | test.replace_with_new_op
11
+ func.func @replace_with_new_op () -> i32 {
12
+ %a = " test.replace_with_new_op" () : () -> (i32 )
13
+ %res = arith.addi %a , %a : i32
14
+ return %res : i32
15
+ }
You can’t perform that action at this time.
0 commit comments