@@ -15,17 +15,15 @@ func.func @ceildivi(%arg0: i32, %arg1: i32) -> (i32) {
15
15
// CHECK: [[TRUE1:%.+]] = arith.addi [[X]], [[ARG0]] : i32
16
16
// CHECK: [[TRUE2:%.+]] = arith.divsi [[TRUE1]], [[ARG1]] : i32
17
17
// CHECK: [[TRUE3:%.+]] = arith.addi [[ONE]], [[TRUE2]] : i32
18
- // CHECK: [[FALSE1:%.+]] = arith.subi [[ZERO]], [[ARG0]] : i32
19
- // CHECK: [[FALSE2:%.+]] = arith.divsi [[FALSE1]], [[ARG1]] : i32
20
- // CHECK: [[FALSE3:%.+]] = arith.subi [[ZERO]], [[FALSE2]] : i32
18
+ // CHECK: [[FALSE:%.+]] = arith.divsi [[ARG0]], [[ARG1]] : i32
21
19
// CHECK: [[NNEG:%.+]] = arith.cmpi slt, [[ARG0]], [[ZERO]] : i32
22
20
// CHECK: [[NPOS:%.+]] = arith.cmpi sgt, [[ARG0]], [[ZERO]] : i32
23
21
// CHECK: [[MNEG:%.+]] = arith.cmpi slt, [[ARG1]], [[ZERO]] : i32
24
22
// CHECK: [[MPOS:%.+]] = arith.cmpi sgt, [[ARG1]], [[ZERO]] : i32
25
23
// CHECK: [[TERM1:%.+]] = arith.andi [[NNEG]], [[MNEG]] : i1
26
24
// CHECK: [[TERM2:%.+]] = arith.andi [[NPOS]], [[MPOS]] : i1
27
25
// CHECK: [[CMP2:%.+]] = arith.ori [[TERM1]], [[TERM2]] : i1
28
- // CHECK: [[RES:%.+]] = arith.select [[CMP2]], [[TRUE3]], [[FALSE3 ]] : i32
26
+ // CHECK: [[RES:%.+]] = arith.select [[CMP2]], [[TRUE3]], [[FALSE ]] : i32
29
27
}
30
28
31
29
// -----
@@ -45,17 +43,15 @@ func.func @ceildivi_index(%arg0: index, %arg1: index) -> (index) {
45
43
// CHECK: [[TRUE1:%.+]] = arith.addi [[X]], [[ARG0]] : index
46
44
// CHECK: [[TRUE2:%.+]] = arith.divsi [[TRUE1]], [[ARG1]] : index
47
45
// CHECK: [[TRUE3:%.+]] = arith.addi [[ONE]], [[TRUE2]] : index
48
- // CHECK: [[FALSE1:%.+]] = arith.subi [[ZERO]], [[ARG0]] : index
49
- // CHECK: [[FALSE2:%.+]] = arith.divsi [[FALSE1]], [[ARG1]] : index
50
- // CHECK: [[FALSE3:%.+]] = arith.subi [[ZERO]], [[FALSE2]] : index
46
+ // CHECK: [[FALSE:%.+]] = arith.divsi [[ARG0]], [[ARG1]] : index
51
47
// CHECK: [[NNEG:%.+]] = arith.cmpi slt, [[ARG0]], [[ZERO]] : index
52
48
// CHECK: [[NPOS:%.+]] = arith.cmpi sgt, [[ARG0]], [[ZERO]] : index
53
49
// CHECK: [[MNEG:%.+]] = arith.cmpi slt, [[ARG1]], [[ZERO]] : index
54
50
// CHECK: [[MPOS:%.+]] = arith.cmpi sgt, [[ARG1]], [[ZERO]] : index
55
51
// CHECK: [[TERM1:%.+]] = arith.andi [[NNEG]], [[MNEG]] : i1
56
52
// CHECK: [[TERM2:%.+]] = arith.andi [[NPOS]], [[MPOS]] : i1
57
53
// CHECK: [[CMP2:%.+]] = arith.ori [[TERM1]], [[TERM2]] : i1
58
- // CHECK: [[RES:%.+]] = arith.select [[CMP2]], [[TRUE3]], [[FALSE3 ]] : index
54
+ // CHECK: [[RES:%.+]] = arith.select [[CMP2]], [[TRUE3]], [[FALSE ]] : index
59
55
}
60
56
61
57
// -----
0 commit comments