Commit 26fa9076 by Richard Guenther Committed by Richard Biener

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
parent 6054bf2a
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> 2008-05-26 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/36253 PR middle-end/36253
......
...@@ -1139,8 +1139,8 @@ defs_to_varying (tree stmt) ...@@ -1139,8 +1139,8 @@ defs_to_varying (tree stmt)
return changed; return changed;
} }
static tree static bool expr_has_constants (tree expr);
try_to_simplify (tree stmt, tree rhs); static tree try_to_simplify (tree stmt, tree rhs);
/* Visit a copy between LHS and RHS, return true if the value number /* Visit a copy between LHS and RHS, return true if the value number
changed. */ changed. */
...@@ -1245,6 +1245,7 @@ visit_reference_op_load (tree lhs, tree op, tree stmt) ...@@ -1245,6 +1245,7 @@ visit_reference_op_load (tree lhs, tree op, tree stmt)
/* Initialize value-number information properly. */ /* Initialize value-number information properly. */
VN_INFO_GET (result)->valnum = result; VN_INFO_GET (result)->valnum = result;
VN_INFO (result)->expr = val; VN_INFO (result)->expr = val;
VN_INFO (result)->has_constants = expr_has_constants (val);
VN_INFO (result)->needs_insertion = true; VN_INFO (result)->needs_insertion = true;
/* As all "inserted" statements are singleton SCCs, insert /* As all "inserted" statements are singleton SCCs, insert
to the valid table. This is strictly needed to to the valid table. This is strictly needed to
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment