shl(int x,int y)1 static int shl(int x, int y)
2 {
3 return x << y;
4 }
5
ushl(unsigned int x,unsigned int y)6 static unsigned int ushl(unsigned int x, unsigned int y)
7 {
8 return x << y;
9 }
10
shr(int x,int y)11 static int shr(int x, int y)
12 {
13 return x >> y;
14 }
15
ushr(unsigned int x,unsigned int y)16 static unsigned int ushr(unsigned int x, unsigned int y)
17 {
18 return x >> y;
19 }
20
and(int x,int y)21 static int and(int x, int y)
22 {
23 return x & y;
24 }
25
uand(unsigned int x,unsigned int y)26 static unsigned int uand(unsigned int x, unsigned int y)
27 {
28 return x & y;
29 }
30
or(int x,int y)31 static int or(int x, int y)
32 {
33 return x | y;
34 }
35
uor(unsigned int x,unsigned int y)36 static unsigned int uor(unsigned int x, unsigned int y)
37 {
38 return x | y;
39 }
40
xor(int x,int y)41 static int xor(int x, int y)
42 {
43 return x ^ y;
44 }
45
uxor(unsigned int x,unsigned int y)46 static unsigned int uxor(unsigned int x, unsigned int y)
47 {
48 return x ^ y;
49 }
50
not(int x)51 static int not(int x)
52 {
53 return ~x;
54 }
55
unot(unsigned int x)56 static unsigned int unot(unsigned int x)
57 {
58 return ~x;
59 }
60
61 /*
62 * check-name: Bitwise operator code generation
63 * check-command: sparsec -c $file -o tmp.o
64 */
65