Merge from mainline.
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / recip-6.c
blob60fefd01da5ebe25da3b5526754fc6a5ef497b11
1 /* { dg-options "-O1 -funsafe-math-optimizations -fno-trapping-math -fdump-tree-recip" } */
2 /* { dg-do compile } */
4 /* Test inserting in a block that does not contain a division. */
6 extern int f2();
8 double f1(double y, double z, double w)
10 double b, c, d, e, f;
12 if (g ())
13 b = 1 / y, c = z / y;
14 else
15 b = 3 / y, c = w / y;
17 d = b / y;
18 e = c / y;
19 f = 1 / y;
21 return d + e + f;
24 /* { dg-final { scan-tree-dump-times " / " 1 "recip" } } */
25 /* { dg-final { cleanup-tree-dump "recip" } } */