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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.dg/] [tree-ssa/] [recip-2.c] - Blame information for rev 816

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
/* { dg-do compile } */
2
/* { dg-options "-O1 -funsafe-math-optimizations -fdump-tree-recip" } */
3
 
4
float e(float a, float b, float c, float d, float e, float f)
5
{
6
  if (a < b)
7
    {
8
      a = a + b;
9
      c = c + d;
10
    }
11
 
12
  /* The PHI nodes for these divisions should be combined.  */
13
  d = d / a;
14
  e = e / a;
15
  f = f / a;
16
 
17
  a = a / c;
18
  b = b / c;
19
 
20
  /* This should not be left as a multiplication.  */
21
  c = 1 / c;
22
 
23
  return a + b + c + d + e + f;
24
}
25
 
26
/* { dg-final { scan-tree-dump-times " / " 2 "recip" } } */
27
/* { dg-final { scan-tree-dump-times " \\* " 5 "recip" } } */
28
/* { dg-final { cleanup-tree-dump "recip" } } */

powered by: WebSVN 2.1.0

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