blob: 2792b57bd768cfdbc375e2c9f195aa9a097fce4c [file] [log] [blame]
Dan Gohman8c89a502007-08-15 13:36:28 +00001; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep cmp | count 1
2; RUN: llvm-upgrade < %s | llvm-as | llc -march=x86 | grep test | count 1
Dan Gohmanf17a25c2007-07-18 16:29:46 +00003
4int %f1(int %X, int* %y) {
5 %tmp = load int* %y
6 %tmp = seteq int %tmp, 0
7 br bool %tmp, label %ReturnBlock, label %cond_true
8
9cond_true:
10 ret int 1
11
12ReturnBlock:
13 ret int 0
14}
15
16int %f2(int %X, int* %y) {
17 %tmp = load int* %y
18 %tmp1 = shl int %tmp, ubyte 3
19 %tmp1 = seteq int %tmp1, 0
20 br bool %tmp1, label %ReturnBlock, label %cond_true
21
22cond_true:
23 ret int 1
24
25ReturnBlock:
26 ret int 0
27}