merge with trunk @ 139506
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / recip-7.c
blob98bbdca6e2cb5d3e397b78560283ba20a9dd92d8
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 double h();
8 double m, n, o;
10 void f(int x, double z, double w)
12 double b, c, d, e, f;
13 double y = h ();
15 if (x)
16 b = 1 / y, c = z / y;
17 else
18 b = 3 / y, c = w / y;
20 d = b / y;
21 e = c / y;
22 f = 1 / y;
24 m = d;
25 n = e;
26 o = f;
29 /* { dg-final { scan-tree-dump-times " / " 1 "recip" } } */
30 /* { dg-final { cleanup-tree-dump "recip" } } */