blob: d8914415029050fe8e153a1653b60f45c05932a2 [file] [log] [blame]
Rafael Espindola450856d2006-12-12 00:37:38 +00001; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
Evan Cheng02b985c2007-01-19 09:20:23 +00002; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep mvn | wc -l | grep 8
Rafael Espindola450856d2006-12-12 00:37:38 +00003
Rafael Espindolaf64945d2006-12-12 01:03:11 +00004int %f1() {
5entry:
6 ret int -1
7}
Rafael Espindola450856d2006-12-12 00:37:38 +00008
9int %f2(int %a) {
10entry:
11 %tmpnot = xor int %a, -1 ; <int> [#uses=1]
12 ret int %tmpnot
13}
14
Evan Cheng02b985c2007-01-19 09:20:23 +000015int %f3(int %a) {
16entry:
17 %tmp1 = shl int %a, ubyte 2 ; <int> [#uses=1]
18 %tmp1not = xor int %tmp1, -1 ; <int> [#uses=1]
19 ret int %tmp1not
20}
Rafael Espindola450856d2006-12-12 00:37:38 +000021
22int %f4(int %a, ubyte %b) {
23entry:
24 %tmp3 = shl int %a, ubyte %b ; <int> [#uses=1]
25 %tmp3not = xor int %tmp3, -1 ; <int> [#uses=1]
26 ret int %tmp3not
27}
28
Evan Cheng02b985c2007-01-19 09:20:23 +000029uint %f5(uint %a) {
30entry:
31 %tmp1 = lshr uint %a, ubyte 2 ; <uint> [#uses=1]
32 %tmp1not = xor uint %tmp1, 4294967295 ; <uint> [#uses=1]
33 ret uint %tmp1not
34}
Rafael Espindola450856d2006-12-12 00:37:38 +000035
36uint %f6(uint %a, ubyte %b) {
37entry:
38 %tmp2 = lshr uint %a, ubyte %b ; <uint> [#uses=1]
39 %tmp2not = xor uint %tmp2, 4294967295 ; <uint> [#uses=1]
40 ret uint %tmp2not
41}
42
Evan Cheng02b985c2007-01-19 09:20:23 +000043int %f7(int %a) {
44entry:
45 %tmp1 = ashr int %a, ubyte 2 ; <int> [#uses=1]
46 %tmp1not = xor int %tmp1, -1 ; <int> [#uses=1]
47 ret int %tmp1not
48}
Rafael Espindola450856d2006-12-12 00:37:38 +000049
50int %f8(int %a, ubyte %b) {
51entry:
52 %tmp3 = ashr int %a, ubyte %b ; <int> [#uses=1]
53 %tmp3not = xor int %tmp3, -1 ; <int> [#uses=1]
54 ret int %tmp3not
55}
Rafael Espindola24267752006-12-12 14:03:29 +000056
57int %f9() {
58entry:
59 %tmp4845 = add int 0, 0
60 br label %cond_true4848
61
62cond_true4848: ; preds = %bb4835
63 %tmp4851 = sub int -3, 0 ; <int> [#uses=1]
64 %abc = add int %tmp4851, %tmp4845
65 ret int %abc
66}
Rafael Espindolaa898ce62006-12-12 17:10:13 +000067
68bool %f10(int %a) {
69entry:
70 %tmp102 = seteq int -2, %a ; <bool> [#uses=1]
71 ret bool %tmp102
72}