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

Subversion Repositories scarts

[/] [scarts/] [trunk/] [toolchain/] [scarts-gcc/] [gcc-4.1.1/] [gcc/] [testsuite/] [gcc.dg/] [tree-ssa/] [loop-11.c] - Blame information for rev 12

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 12 jlechner
/* A test for final value replacement and higher-order ivs,
2
   see PR 22442.  */
3
 
4
/* { dg-do compile } */
5
/* { dg-options "-O1 -fdump-tree-vars" } */
6
 
7
void bar (unsigned);
8
 
9
void foo (void)
10
{
11
  unsigned i, a;
12
 
13
  for (i = 0; i < 5; i++)
14
    a = i * i;
15
 
16
  bar (a);
17
}
18
 
19
/* Final value of a gets replaced.  */
20
 
21
/* { dg-final { scan-tree-dump-times "\\(16\\)" 1 "vars" } } */
22
 
23
/* And the empty loop is removed.  */
24
 
25
/* { dg-final { scan-tree-dump-times "if " 0 "vars" } } */
26
 
27
/* { dg-final { cleanup-tree-dump "vars" } } */
28
 

powered by: WebSVN 2.1.0

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