summaryrefslogtreecommitdiff
path: root/gcc/simplify-rtx.c
diff options
context:
space:
mode:
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2006-10-21 10:13:13 +0000
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2006-10-21 10:13:13 +0000
commitb5518e7e9563974c4669e178b99af029cd2fcbd1 (patch)
tree6c093b5eb77bcbd360178a0be1846db44e36d9ec /gcc/simplify-rtx.c
parentd11b55fd54ca4c53815412899c4c768ce0059e69 (diff)
downloadgcc-b5518e7e9563974c4669e178b99af029cd2fcbd1.tar.gz
2006-10-21 Richard Guenther <rguenther@suse.de>
PR middle-end/28796 * simplify-rtx.c (simplify_const_relational_operation): Do not constant-fold ORDERED and UNORDERED for flag_unsafe_math_optimizations but only we do not need to honor NaNs for the given mode. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@117928 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/simplify-rtx.c')
-rw-r--r--gcc/simplify-rtx.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/simplify-rtx.c b/gcc/simplify-rtx.c
index 3b12b20e682..fee07f9b5b8 100644
--- a/gcc/simplify-rtx.c
+++ b/gcc/simplify-rtx.c
@@ -3747,10 +3747,10 @@ simplify_const_relational_operation (enum rtx_code code,
return simplify_const_relational_operation (signed_condition (code),
mode, tem, const0_rtx);
- if (flag_unsafe_math_optimizations && code == ORDERED)
+ if (! HONOR_NANS (mode) && code == ORDERED)
return const_true_rtx;
- if (flag_unsafe_math_optimizations && code == UNORDERED)
+ if (! HONOR_NANS (mode) && code == UNORDERED)
return const0_rtx;
/* For modes without NaNs, if the two operands are equal, we know the