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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.dg/] [no-strict-overflow-6.c] - Blame information for rev 853

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

Line No. Rev Author Line
1 149 jeremybenn
/* { dg-do compile } */
2
/* { dg-options "-fno-strict-overflow -O2 -fdump-tree-final_cleanup" } */
3
 
4
/* Source: Ian Lance Taylor.  */
5
 
6
/* VRP test.  We can not simplify the conditional when not using
7
   strict overflow semantics.  We don't test this with
8
   -fstrict-overflow because it turns into an infinite loop.  That is
9
   OK but it would also be OK to not do that.  */
10
 
11
int
12
foo ()
13
{
14
  int i, bits;
15
  for (i = 1, bits = 1; i > 0; i += i)
16
    ++bits;
17
  return bits;
18
}
19
 
20
/* { dg-final { scan-tree-dump "return bits" "final_cleanup" } } */
21
/* { dg-final { cleanup-tree-dump "final_cleanup" } } */

powered by: WebSVN 2.1.0

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