int flag_unsafe_math_optimizations = 0;
+/* Nonzero means that no NaNs or +-Infs are expected. */
+
+int flag_finite_math_only = 0;
+
/* Zero means that floating-point math operations cannot generate a
(user-visible) trap. This is the case, for example, in nonstop
IEEE 754 arithmetic. Trapping conditions include division by zero,
N_("Process #ident directives") },
{ "peephole2", &flag_peephole2, 1,
N_("Enables an rtl peephole pass run before sched2") },
+ {"finite-math-only", &flag_finite_math_only, 1,
+ N_("Assume no NaNs or +-Infs are generated") },
{ "guess-branch-probability", &flag_guess_branch_prob, 1,
N_("Enables guessing of branch probabilities") },
{"math-errno", &flag_errno_math, 1,
{
flag_trapping_math = !set;
flag_unsafe_math_optimizations = set;
+ flag_finite_math_only = set;
flag_errno_math = !set;
if (set)
flag_signaling_nans = 0;
{
return (!flag_trapping_math
&& flag_unsafe_math_optimizations
+ && flag_finite_math_only
&& !flag_errno_math);
}