libcpp, c, middle-end: Optimize initializers using #embed in C
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / mult-abs-2.c
blob675127cfe56b2e9aa9d4c06e2bdce62b59545a08
1 /* { dg-do compile } */
2 /* { dg-require-effective-target c99_runtime } */
3 /* { dg-options "-O2 -ffast-math -fdump-tree-gimple" } */
5 float f(float x)
7 return x * (x > 0.f ? -1.f : 1.f);
9 float f1(float x)
11 return x * (x > 0.f ? 1.f : -1.f);
13 float g(float x)
15 return x * (x >= 0.f ? -1.f : 1.f);
17 float g1(float x)
19 return x * (x >= 0.f ? 1.f : -1.f);
21 float h(float x)
23 return x * (x < 0.f ? -1.f : 1.f);
25 float h1(float x)
27 return x * (x < 0.f ? 1.f : -1.f);
29 float i(float x)
31 return x * (x <= 0.f ? -1.f : 1.f);
33 float i1(float x)
35 return x * (x <= 0.f ? 1.f : -1.f);
38 /* { dg-final { scan-tree-dump-times "ABS" 8 "gimple" } } */