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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [20030324-1.c] - Blame information for rev 774

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 689 jeremybenn
/* { dg-do run } */
2
/* { dg-options "-O -fstrict-aliasing -fgcse" } */
3
 
4
/* PR optimization/10087 */
5
/* Contributed by Peter van Hoof <p.van-hoof@qub.ac.uk> */
6
 
7
extern void abort(void);
8
 
9
void b(int*,int*);
10
 
11
typedef struct {
12
    double T1;
13
    char c;
14
} S;
15
 
16
int main(void)
17
{
18
  int i,j;
19
  double s;
20
 
21
  S x1[2][2];
22
  S *x[2] = { x1[0], x1[1] };
23
  S **E = x;
24
 
25
  for( i=0; i < 2; i++ )
26
    for( j=0; j < 2; j++ )
27
      E[j][i].T1 = 1;
28
 
29
  for( i=0; i < 2; i++ )
30
    for( j=0; j < 2; j++ )
31
      s = E[j][i].T1;
32
 
33
  b(&j,&i);
34
  if (s != 1)
35
    abort ();
36
  return 0;
37
}
38
 
39
void b(int *i, int *j) {}

powered by: WebSVN 2.1.0

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