xref: /llvm-project/llvm/test/Transforms/InstCombine/oss_fuzz_32759.ll (revision ad7f02010f32bff28fec139e103ad0240e160aa9)
1; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
2; RUN: opt < %s -passes=instcombine -S | FileCheck %s
3target datalayout = "n32"
4
5define i1 @oss_fuzz_32759(i1 %y, i1 %c1) {
6; CHECK-LABEL: @oss_fuzz_32759(
7; CHECK-NEXT:  entry:
8; CHECK-NEXT:    br i1 [[C1:%.*]], label [[COND_TRUE:%.*]], label [[END:%.*]]
9; CHECK:       cond.true:
10; CHECK-NEXT:    br label [[END]]
11; CHECK:       end:
12; CHECK-NEXT:    ret i1 false
13;
14entry:
15  br i1 %c1, label %cond.true, label %end
16
17cond.true:                                        ; preds = %entry
18  %zy = zext i1 %y to i32
19  %B6 = shl i32 %zy, 2147483647
20  %B3 = ashr i32 %B6, 2147483647
21  %B7 = srem i32 %B3, 123
22  %cond = xor i32 %B7, %B3
23  br label %end
24
25end:                                              ; preds = %cond.true, %entry
26  %p = phi i32 [ %cond, %cond.true ], [ -1, %entry ]
27  %r = icmp eq i32 %p, 0
28  ret i1 %r
29}
30