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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [pr51481.c] - Blame information for rev 801

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

Line No. Rev Author Line
1 689 jeremybenn
/* PR tree-optimization/51481 */
2
/* { dg-do compile } */
3
/* { dg-options "-O -fexceptions -fipa-cp -fipa-cp-clone" } */
4
 
5
extern const unsigned short int **foo (void)
6
  __attribute__ ((__nothrow__, __const__));
7
struct S { unsigned short s1; int s2; };
8
extern struct S *s[26];
9
 
10
void
11
bar (int x, struct S *y, ...)
12
{
13
  static struct S *t;
14
  __builtin_va_list ap;
15
  __builtin_va_start (ap, y);
16
  if (t != s[7])
17
    {
18
      const char *p = "aAbBc";
19
      t = s[7];
20
      while ((*foo ())[(unsigned char) *p])
21
        p++;
22
    }
23
  __builtin_printf (x == 0 ? "abc\n" : "def\n");
24
  if (y != 0)
25
    __builtin_printf ("ghi %d %d", y->s2, y->s1);
26
  __builtin_va_end (ap);
27
}
28
 
29
void
30
baz (char *x)
31
{
32
  bar (1, 0, x);
33
}

powered by: WebSVN 2.1.0

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