From: Richard Guenther Date: Sun, 4 Jul 2010 11:38:01 +0000 (+0000) Subject: 2010-07-4 Richard Guenther X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ef2a9157f4bbd2b7c5cd93328732a94970234173;p=gcc.git 2010-07-4 Richard Guenther * tree-ssa-sccvn.c (vn_reference_lookup_3): Fix last commit. From-SVN: r161799 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index fb5486576c0..b7b6b00ebcc 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2010-07-04 Richard Guenther + + * tree-ssa-sccvn.c (vn_reference_lookup_3): Fix last commit. + 2010-07-04 Richard Guenther PR tree-optimization/44656 diff --git a/gcc/tree-ssa-sccvn.c b/gcc/tree-ssa-sccvn.c index cca1941f7b3..b121309a124 100644 --- a/gcc/tree-ssa-sccvn.c +++ b/gcc/tree-ssa-sccvn.c @@ -1218,12 +1218,12 @@ vn_reference_lookup_3 (ao_ref *ref, tree vuse, void *vr_) tree lhs = gimple_assign_lhs (def_stmt); ao_ref ref1; VEC (vn_reference_op_s, heap) *operands = NULL; - bool res; + bool res = true; copy_reference_ops_from_ref (lhs, &operands); operands = valueize_refs (operands); - ao_ref_init_from_vn_reference (&ref1, get_alias_set (lhs), - TREE_TYPE (lhs), operands); - res = refs_may_alias_p_1 (ref, &ref1, true); + if (ao_ref_init_from_vn_reference (&ref1, get_alias_set (lhs), + TREE_TYPE (lhs), operands)) + res = refs_may_alias_p_1 (ref, &ref1, true); VEC_free (vn_reference_op_s, heap, operands); if (!res) return NULL;