libcpp, c, middle-end: Optimize initializers using #embed in C
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / copy-sign-1.c
blob617a8411303778d56f397cee50c69c337f207fa8
1 /* { dg-do compile } */
2 /* { dg-require-effective-target c99_runtime } */
3 /* { dg-options "-O2 -ffast-math -fdump-tree-gimple" } */
4 float f(float x)
6 return (x > 0.f ? -1.f : 1.f);
8 float f1(float x)
10 return (x > 0.f ? 1.f : -1.f);
12 float g(float x)
14 return (x >= 0.f ? -1.f : 1.f);
16 float g1(float x)
18 return (x >= 0.f ? 1.f : -1.f);
20 float h(float x)
22 return (x < 0.f ? -1.f : 1.f);
24 float h1(float x)
26 return (x < 0.f ? 1.f : -1.f);
28 float i(float x)
30 return (x <= 0.f ? -1.f : 1.f);
32 float i1(float x)
34 return (x <= 0.f ? 1.f : -1.f);
36 /* { dg-final { scan-tree-dump-not "copysign" "gimple"} } */