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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [pr48156.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 rtl-optimization/48156 */
2
/* { dg-do run } */
3
/* { dg-options "-O -fcrossjumping --param min-crossjump-insns=1" } */
4
 
5
extern void abort (void);
6
 
7
static int __attribute__ ((noinline, noclone))
8
equals (int s1, int s2)
9
{
10
  return s1 == s2;
11
}
12
 
13
static int __attribute__ ((noinline, noclone))
14
bar (void)
15
{
16
  return 1;
17
}
18
 
19
static void __attribute__ ((noinline, noclone))
20
baz (int f, int j)
21
{
22
  if (f != 4 || j != 2)
23
    abort ();
24
}
25
 
26
void
27
foo (int x)
28
{
29
  int i = 0, j = bar ();
30
 
31
  if (x == 1)
32
    i = 2;
33
 
34
  if (j && equals (i, j))
35
    baz (8, i);
36
  else
37
    baz (4, i);
38
}
39
 
40
int
41
main ()
42
{
43
  foo (1);
44
  return 0;
45
}

powered by: WebSVN 2.1.0

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