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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.dg/] [pr23518.c] - Blame information for rev 826

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 298 jeremybenn
/* PR tree-optimization/23518.
2
   make_range used to transform a + 1 < 0 into a < -1 even when a is
3
   signed and -fwrapv is given.  Make sure that no longer happens.  */
4
 
5
/* { dg-do run } */
6
/* { dg-options "-O2 -fwrapv" } */
7
 
8
#include <limits.h>
9
 
10
extern void abort (void);
11
extern void exit (int);
12
 
13
int
14
main (void)
15
{
16
  int a = INT_MAX;
17
  if ((a < 0) || (a + 1 < 0))
18
    exit (0);
19
 
20
  abort ();
21
}

powered by: WebSVN 2.1.0

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