1 // RUN: mlir-opt -test-print-defuse -allow-unregistered-dialect %s | FileCheck %s
3 // CHECK: Visiting op 'dialect.op1' with 0 operands:
4 // CHECK: Has 4 results:
5 // CHECK: - Result 0 has a single use: - dialect.op2
6 // CHECK: - Result 1 has no uses
7 // CHECK: - Result 2 has 2 uses:
8 // CHECK: - dialect.innerop1
9 // CHECK: - dialect.op2
10 // CHECK: - Result 3 has no uses
11 // CHECK: Visiting op 'dialect.op2' with 2 operands:
12 // CHECK: - Operand produced by operation 'dialect.op1'
13 // CHECK: - Operand produced by operation 'dialect.op1'
14 // CHECK: Has 0 results:
15 // CHECK: Visiting op 'dialect.innerop1' with 2 operands:
16 // CHECK: - Operand produced by Block argument, number 0
17 // CHECK: - Operand produced by operation 'dialect.op1'
18 // CHECK: Has 0 results:
19 // CHECK: Visiting op 'dialect.op3' with 0 operands:
20 // CHECK: Has 0 results:
21 // CHECK: Visiting op 'builtin.module' with 0 operands:
22 // CHECK: Has 0 results:
24 %results:4 = "dialect.op1"() : () -> (i1, i16, i32, i64)
25 "dialect.op2"(%results#0, %results#2) : (i1, i32) -> ()
28 "dialect.innerop1"(%arg0, %results#2) : (i1, i32) -> ()