Eli Friedman | 049d08f | 2012-03-05 23:09:40 +0000 | [diff] [blame] | 1 | ; RUN: opt < %s -instsimplify -S | FileCheck %s |
2 | |||||
3 | ; PR12189 | ||||
4 | define i1 @test1(i32 %x) { | ||||
5 | ; CHECK: @test1 | ||||
6 | br i1 true, label %a, label %b | ||||
7 | |||||
8 | a: | ||||
9 | %aa = or i32 %x, 10 | ||||
10 | br label %c | ||||
11 | |||||
12 | b: | ||||
13 | %bb = or i32 %x, 10 | ||||
14 | br label %c | ||||
15 | |||||
16 | c: | ||||
17 | %cc = phi i32 [ %bb, %b ], [%aa, %a ] | ||||
18 | %d = urem i32 %cc, 2 | ||||
19 | %e = icmp eq i32 %d, 0 | ||||
20 | ret i1 %e | ||||
21 | ; CHECK: ret i1 %e | ||||
22 | } |