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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.c-torture/] [execute/] [20010409-1.c] - Blame information for rev 816

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
typedef __SIZE_TYPE__ size_t;
2
extern size_t strlen (const char *s);
3
 
4
typedef struct A {
5
  int a, b;
6
} A;
7
 
8
typedef struct B {
9
  struct A **a;
10
  int b;
11
} B;
12
 
13
A *a;
14
int b = 1, c;
15
B d[1];
16
 
17
void foo (A *x, const char *y, int z)
18
{
19
  c = y[4] + z * 25;
20
}
21
 
22
A *bar (const char *v, int w, int x, const char *y, int z)
23
{
24
  if (w)
25
    abort ();
26
  exit (0);
27
}
28
 
29
void test (const char *x, int *y)
30
{
31
  foo (d->a[d->b], "test", 200);
32
  d->a[d->b] = bar (x, b ? 0 : 65536, strlen (x), "test", 201);
33
  d->a[d->b]->a++;
34
  if (y)
35
    d->a[d->b]->b = *y;
36
}
37
 
38
int main ()
39
{
40
  d->b = 0;
41
  d->a = &a;
42
  test ("", 0);
43
}

powered by: WebSVN 2.1.0

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