aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2008-05-26 15:51:16 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2008-05-26 15:51:16 +0000
commit26fa9076d9e62320e3155b9e11491f0449612a2d (patch)
tree74a18db2579cf265a9008e69ab843a977ffc4bf7
parent6054bf2a351ce0cbf86a14d60bea94b85e0004be (diff)
downloadgcc-26fa9076d9e62320e3155b9e11491f0449612a2d.zip
gcc-26fa9076d9e62320e3155b9e11491f0449612a2d.tar.gz
gcc-26fa9076d9e62320e3155b9e11491f0449612a2d.tar.bz2
tree-ssa-sccvn.c (expr_has_constants): Declare.
2008-05-26 Richard Guenther <rguenther@suse.de> * tree-ssa-sccvn.c (expr_has_constants): Declare. (visit_reference_op_load): Initialize VN_INFO->has_constants properly. From-SVN: r135943
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/tree-ssa-sccvn.c5
2 files changed, 9 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index a6fad4f..eca37f9 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2008-05-26 Richard Guenther <rguenther@suse.de>
+
+ * tree-ssa-sccvn.c (expr_has_constants): Declare.
+ (visit_reference_op_load): Initialize VN_INFO->has_constants
+ properly.
+
2008-05-26 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/36253
diff --git a/gcc/tree-ssa-sccvn.c b/gcc/tree-ssa-sccvn.c
index 86777c7..c4c13f9 100644
--- a/gcc/tree-ssa-sccvn.c
+++ b/gcc/tree-ssa-sccvn.c
@@ -1139,8 +1139,8 @@ defs_to_varying (tree stmt)
return changed;
}
-static tree
-try_to_simplify (tree stmt, tree rhs);
+static bool expr_has_constants (tree expr);
+static tree try_to_simplify (tree stmt, tree rhs);
/* Visit a copy between LHS and RHS, return true if the value number
changed. */
@@ -1245,6 +1245,7 @@ visit_reference_op_load (tree lhs, tree op, tree stmt)
/* Initialize value-number information properly. */
VN_INFO_GET (result)->valnum = result;
VN_INFO (result)->expr = val;
+ VN_INFO (result)->has_constants = expr_has_constants (val);
VN_INFO (result)->needs_insertion = true;
/* As all "inserted" statements are singleton SCCs, insert
to the valid table. This is strictly needed to