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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.c-torture/] [execute/] [pr17133.c] - Blame information for rev 298

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

Line No. Rev Author Line
1 297 jeremybenn
extern void abort (void);
2
 
3
int foo = 0;
4
void *bar = 0;
5
unsigned int baz = 100;
6
 
7
void *pure_alloc ()
8
{
9
  void *res;
10
 
11
  while (1)
12
    {
13
      res = (void *) ((((unsigned int) (foo + bar))) & ~1);
14
      foo += 2;
15
      if (foo < baz)
16
        return res;
17
      foo = 0;
18
    }
19
}
20
 
21
int main ()
22
{
23
  pure_alloc ();
24
  if (!foo)
25
    abort ();
26
  return 0;
27
}

powered by: WebSVN 2.1.0

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