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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.c-torture/] [compile/] [pr24930.c] - Blame information for rev 859

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

Line No. Rev Author Line
1 297 jeremybenn
/* PR 24930 */
2
extern int foo(int u) __attribute__((noinline));
3
int foo(int u) {return 0;}
4
int
5
main(int argc, char** argv)
6
{
7
  const char *buf = argv[1];
8
 
9
  unsigned int data = (((unsigned int) buf[0]) << 8) + (unsigned int) buf[1];
10
  if (data & 0x8000) {
11
    data &= 0x7fff ;
12
    data ^= 0x7fff ;
13
    data += 1 ;
14
    data *= -1 ;
15
  }
16
  return foo((int)data);
17
}

powered by: WebSVN 2.1.0

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