1 ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
2 ; RUN: opt < %s -passes=instcombine -S | FileCheck %s
7 define i1 @test(i32 %In) {
9 ; CHECK-NEXT: [[C2:%.*]] = icmp eq i32 [[IN:%.*]], 15
10 ; CHECK-NEXT: ret i1 [[C2]]
12 %c1 = icmp ugt i32 %In, 13
13 %c2 = icmp eq i32 %In, 15
18 define i1 @test_logical(i32 %In) {
19 ; CHECK-LABEL: @test_logical(
20 ; CHECK-NEXT: [[C2:%.*]] = icmp eq i32 [[IN:%.*]], 15
21 ; CHECK-NEXT: ret i1 [[C2]]
23 %c1 = icmp ugt i32 %In, 13
24 %c2 = icmp eq i32 %In, 15
25 %V = select i1 %c1, i1 %c2, i1 false