OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.target/] [i386/] [20000614-2.c] - Blame information for rev 318

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 318 jeremybenn
/* { dg-do run } */
2
/* { dg-options "-O2" } */
3
 
4
extern void abort (void);
5
extern void exit (int);
6
 
7
char buf[8];
8
 
9
void bar(char *p)
10
{
11
}
12
 
13
int main()
14
{
15
  union {
16
    unsigned int val;
17
    unsigned char p[4];
18
  } serial;
19
 
20
  int i;
21
  serial.val = 0;
22
  bar(buf);
23
  for(i = 0; i < 8; i += 4)
24
    {
25
      serial.p [0] += buf [i + 0];
26
      serial.p [1] += buf [i + 1];
27
      serial.p [2] += buf [i + 2];
28
      serial.p [3] += buf [i + 3];
29
    }
30
  if (serial.val)
31
    abort();
32
  exit(0);
33
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.