Debian Codegraph @

gcc/testsuite/gcc.c-torture/execute/longlong.c

raw
1 /* Source: PR 321 modified for test suite by Neil Booth 14 Jan 2001. */
2
3 void abort (void);
4 void exit (int);
5
6 typedef unsigned long long uint64;
7 unsigned long pars;
8
9 uint64 b[32];
10 uint64 *r = b;
11
12 void alpha_ep_extbl_i_eq_0()
13 {
14 unsigned int rb, ra, rc;
15
16 rb = (((unsigned long)(pars) >> 27)) & 0x1fUL;
17 ra = (((unsigned int)(pars) >> 5)) & 0x1fUL;
18 rc = (((unsigned int)(pars) >> 0)) & 0x1fUL;
19 {
20 uint64 temp = ((r[ra] >> ((r[rb] & 0x7) << 3)) & 0x00000000000000FFLL);
21 if (rc != 31)
22 r[rc] = temp;
23 }
24 }
25
26 int
27 main(void)
28 {
29 if (sizeof (uint64) == 8)
30 {
31 b[17] = 0x0000000000303882ULL; /* rb */
32 b[2] = 0x534f4f4c494d000aULL; /* ra & rc */
33
34 pars = 0x88000042; /* 17, 2, 2 coded */
35 alpha_ep_extbl_i_eq_0();
36
37 if (b[2] != 0x4d)
38 abort ();
39 }
40
41 exit (0);
42 }