summaryrefslogtreecommitdiff
path: root/gcc/tree.c
diff options
context:
space:
mode:
authorRichard Kenner <kenner@vlsi1.ultra.nyu.edu>1999-12-20 21:23:30 +0000
committerRichard Kenner <kenner@gcc.gnu.org>1999-12-20 16:23:30 -0500
commite545d37f6d993df2f2f56f957603b741ae2b9af8 (patch)
tree1eb9a1ccf7a778ffa3f7c87c99fb6ca04449a694 /gcc/tree.c
parentb70104128862fc1af6ca8d853a1fdabb3d6b799f (diff)
downloadgcc-e545d37f6d993df2f2f56f957603b741ae2b9af8.tar.gz
* tree.c (real_value_from_int_cst): Clear REAL_VALUE_TYPE object first.
From-SVN: r31038
Diffstat (limited to 'gcc/tree.c')
-rw-r--r--gcc/tree.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/tree.c b/gcc/tree.c
index 6f6caf94f74..dd8a6d4994a 100644
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -1425,6 +1425,10 @@ real_value_from_int_cst (type, i)
REAL_VALUE_TYPE d;
#ifdef REAL_ARITHMETIC
+ /* Clear all bits of the real value type so that we can later do
+ bitwise comparisons to see if two values are the same. */
+ bzero ((char *) &d, sizeof d);
+
if (! TREE_UNSIGNED (TREE_TYPE (i)))
REAL_VALUE_FROM_INT (d, TREE_INT_CST_LOW (i), TREE_INT_CST_HIGH (i),
TYPE_MODE (type));