From 90310d368fad6dde921b6a1477ea0bac387a6ca2 Mon Sep 17 00:00:00 2001 From: Richard Guenther Date: Tue, 23 Oct 2007 11:20:56 +0000 Subject: alias.c (get_alias_set): For INDIRECT_REFs, deal with SSA_NAME pointers. 2007-10-23 Richard Guenther * alias.c (get_alias_set): For INDIRECT_REFs, deal with SSA_NAME pointers. From-SVN: r129577 --- gcc/alias.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'gcc/alias.c') diff --git a/gcc/alias.c b/gcc/alias.c index 6bf67f3574f..bd5c277f05a 100644 --- a/gcc/alias.c +++ b/gcc/alias.c @@ -525,7 +525,12 @@ get_alias_set (tree t) /* Check for accesses through restrict-qualified pointers. */ if (INDIRECT_REF_P (inner)) { - tree decl = find_base_decl (TREE_OPERAND (inner, 0)); + tree decl; + + if (TREE_CODE (TREE_OPERAND (inner, 0)) == SSA_NAME) + decl = SSA_NAME_VAR (TREE_OPERAND (inner, 0)); + else + decl = find_base_decl (TREE_OPERAND (inner, 0)); if (decl && DECL_POINTER_ALIAS_SET_KNOWN_P (decl)) { -- cgit v1.2.1