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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.c-torture/] [execute/] [20020904-1.c] - Blame information for rev 774

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

Line No. Rev Author Line
1 688 jeremybenn
/* PR c/7102 */
2
 
3
/* Verify that GCC zero-extends integer constants
4
   in unsigned binary operations. */
5
 
6
typedef unsigned char u8;
7
 
8
u8 fun(u8 y)
9
{
10
  u8 x=((u8)255)/y;
11
  return x;
12
}
13
 
14
int main(void)
15
{
16
  if (fun((u8)2) != 127)
17
    abort ();
18
  return 0;
19
}

powered by: WebSVN 2.1.0

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