File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed
llvm/test/Transforms/InstCombine Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -67,3 +67,24 @@ define <2 x i1> @test3vec(<2 x i32> %a) {
67
67
ret <2 x i1 > %c
68
68
}
69
69
70
+ define i1 @test4 (i32 %a ) {
71
+ ; CHECK-LABEL: @test4(
72
+ ; CHECK-NEXT: [[C:%.*]] = icmp slt i32 %a, -4
73
+ ; CHECK-NEXT: ret i1 [[C]]
74
+ ;
75
+ %b = add i32 %a , 2147483652
76
+ %c = icmp sge i32 %b , 4
77
+ ret i1 %c
78
+ }
79
+
80
+ define <2 x i1 > @test4vec (<2 x i32 > %a ) {
81
+ ; CHECK-LABEL: @test4vec(
82
+ ; CHECK-NEXT: [[B:%.*]] = add <2 x i32> %a, <i32 -2147483644, i32 -2147483644>
83
+ ; CHECK-NEXT: [[C:%.*]] = icmp sgt <2 x i32> [[B]], <i32 3, i32 3>
84
+ ; CHECK-NEXT: ret <2 x i1> [[C]]
85
+ ;
86
+ %b = add <2 x i32 > %a , <i32 2147483652 , i32 2147483652 >
87
+ %c = icmp sge <2 x i32 > %b , <i32 4 , i32 4 >
88
+ ret <2 x i1 > %c
89
+ }
90
+
You can’t perform that action at this time.
0 commit comments