2 /* { dg-do compile } */
3 /* { dg-options "-funsafe-math-optimizations -fno-math-errno -O -Wno-div-by-zero" } */
11 /* Can't trigger some of them because operand_equal_p will return false
14 /* (x & ~m) | (y & m) -> ((x ^ y) & m) ^ x */
19 r
+= (short) (E
& ~u
| i
& u
);
20 r
+= -(short) (E
& ~u
| i
& u
);
21 r
+= (short) -(E
& ~u
| i
& u
);
25 /* sqrt(x) < y is x >= 0 && x != +Inf, when y is large. */
30 r
= __builtin_sqrt (E
) < __builtin_inf ();
34 /* sqrt(x) < c is the same as x >= 0 && x < c*c. */
39 r
= __builtin_sqrt (E
) < 1.3;
43 /* copysign(x,y)*copysign(x,y) -> x*x. */
45 fn4 (double y
, double x
)
47 return __builtin_copysign (E
, y
) * __builtin_copysign (E
, y
);
50 /* x <= +Inf is the same as x == x, i.e. !isnan(x). */
54 return E
<= __builtin_inf ();
57 /* Fold (A & ~B) - (A & B) into (A ^ B) - B. */
61 return (i
& ~E
) - (i
& E
);
64 /* Fold (A & B) - (A & ~B) into B - (A ^ B). */
68 return (i
& E
) - (i
& ~E
);
71 /* x + (x & 1) -> (x + 1) & ~1 */
78 /* Simplify comparison of something with itself. */
82 return E
<= E
| E
>= E
;
85 /* Fold (A & ~B) - (A & B) into (A ^ B) - B. */
89 return (i
& ~E
) - (i
& E
);
92 /* abs(x)*abs(x) -> x*x. Should be valid for all types. */
96 return __builtin_abs (E
) * __builtin_abs (E
);
99 /* (x | CST1) & CST2 -> (x & CST2) | (CST1 & CST2) */
103 return (E
| 11) & 12;
106 /* fold_range_test */
110 return s
[E
] != '\0' && s
[E
] != '/';
113 /* fold_comparison */
117 return (!!i
? : (u
*= E
/ 0)) >= (u
= E
);
120 /* fold_mult_zconjz */
122 fn15 (_Complex
volatile int *z
)