summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>2007-06-11 15:40:52 +0000
committerebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>2007-06-11 15:40:52 +0000
commit2bff6d8b45f3a32ac3ecd70e9f3898f8feba88b5 (patch)
tree1b8157062e08bc40acc9e00f97163fff095d7437
parent4471a4820c81366a9acf8ebc735694c72e2e81be (diff)
downloadgcc-2bff6d8b45f3a32ac3ecd70e9f3898f8feba88b5.tar.gz
* tree-ssa-structalias.c (find_what_p_points_to): Return false
for ref-all pointers that point-to anything. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@125620 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/tree-ssa-structalias.c15
2 files changed, 16 insertions, 4 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 13cb914ebed..a4414797048 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2007-06-11 Eric Botcazou <ebotcazou@adacore.com>
+
+ * tree-ssa-structalias.c (find_what_p_points_to): Return false
+ for ref-all pointers that point-to anything.
+
2007-06-11 Joseph Myers <joseph@codesourcery.com>
* config/arm/arm.c (arm_output_dwarf_dtprel,
diff --git a/gcc/tree-ssa-structalias.c b/gcc/tree-ssa-structalias.c
index 6b470b3143f..d351bf503c2 100644
--- a/gcc/tree-ssa-structalias.c
+++ b/gcc/tree-ssa-structalias.c
@@ -4540,12 +4540,19 @@ find_what_p_points_to (tree p)
finished_solution = BITMAP_GGC_ALLOC ();
stats.points_to_sets_created++;
- /* Instead of using pt_anything, we instead merge in the SMT
- aliases for the underlying SMT. In addition, if they
- could have pointed to anything, they could point to
- global memory. */
+ /* Instead of using pt_anything, we merge in the SMT aliases
+ for the underlying SMT. In addition, if they could have
+ pointed to anything, they could point to global memory.
+ But we cannot do that for ref-all pointers because these
+ aliases have not been computed yet. */
if (was_pt_anything)
{
+ if (PTR_IS_REF_ALL (p))
+ {
+ pi->pt_anything = 1;
+ return false;
+ }
+
merge_smts_into (p, finished_solution);
pi->pt_global_mem = 1;
}