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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.dg/] [20031102-1.c] - Blame information for rev 868

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

Line No. Rev Author Line
1 149 jeremybenn
/* PR optimization/12799 */
2
/* Origin: Pratap Subrahmanyam <pratap@vmware.com> */
3
 
4
/* { dg-do run } */
5
/* { dg-options "-O2" } */
6
/* { dg-options "-O2 -march=i686" { target { { i686-*-* x86_64-*-* } && ilp32 } } } */
7
 
8
/* Verify that reload_cse_move2add doesn't add unexpected CLOBBERs. */
9
 
10
extern void abort(void);
11
 
12
int loo = 1;
13
 
14
__inline__ char InlineFunc(void)
15
{
16
  return __builtin_expect(!!(loo == 1), 1);
17
}
18
 
19
int FooBar(void)
20
{
21
  int i;
22
  int var1 = InlineFunc() ? 2046 : 1023;
23
  int var2 = InlineFunc() ? 512 : 1024;
24
 
25
  for (i = 0; i < var1; i++)
26
    ;
27
 
28
  if (InlineFunc() && var2 != 512)
29
    abort();
30
 
31
  return 0;
32
}
33
 
34
int main(void)
35
{
36
  return FooBar();
37
}

powered by: WebSVN 2.1.0

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