aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2010-10-12 12:56:32 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2010-10-12 12:56:32 +0000
commit1f181fdea6f08eface959ea0786917ccce898c6b (patch)
tree75c0cca2b9391bc3f99d1ccb330405d2f8802b2c
parent85c3f0b9e91b7a4bb421b945577890ebcead33ac (diff)
downloadgcc-1f181fdea6f08eface959ea0786917ccce898c6b.zip
gcc-1f181fdea6f08eface959ea0786917ccce898c6b.tar.gz
gcc-1f181fdea6f08eface959ea0786917ccce898c6b.tar.bz2
tree-ssa-structalias.c (get_constraint_for_1): Constants only point to nonlocal, not anything.
2010-10-12 Richard Guenther <rguenther@suse.de> * tree-ssa-structalias.c (get_constraint_for_1): Constants only point to nonlocal, not anything. From-SVN: r165372
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/tree-ssa-structalias.c11
2 files changed, 15 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index cf4ca0f..9ce3832 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2010-10-12 Richard Guenther <rguenther@suse.de>
+
+ * tree-ssa-structalias.c (get_constraint_for_1): Constants
+ only point to nonlocal, not anything.
+
2010-10-11 Hariharan Sandanagobalane <hariharan@picochip.com>
* config/picochip/picochip.c (TARGET_EXCEPT_UNWIND_INFO): Use sjlj
diff --git a/gcc/tree-ssa-structalias.c b/gcc/tree-ssa-structalias.c
index 83cc953..c2a82ef 100644
--- a/gcc/tree-ssa-structalias.c
+++ b/gcc/tree-ssa-structalias.c
@@ -3335,7 +3335,7 @@ get_constraint_for_1 (tree t, VEC (ce_s, heap) **results, bool address_p,
if (flag_delete_null_pointer_checks)
temp.var = nothing_id;
else
- temp.var = anything_id;
+ temp.var = nonlocal_id;
temp.type = ADDRESSOF;
temp.offset = 0;
VEC_safe_push (ce_s, heap, *results, &temp);
@@ -3428,6 +3428,15 @@ get_constraint_for_1 (tree t, VEC (ce_s, heap) **results, bool address_p,
get_constraint_for_ssa_var (t, results, address_p);
return;
}
+ case tcc_constant:
+ {
+ /* We cannot refer to automatic variables through constants. */
+ temp.type = ADDRESSOF;
+ temp.var = nonlocal_id;
+ temp.offset = 0;
+ VEC_safe_push (ce_s, heap, *results, &temp);
+ return;
+ }
default:;
}