------- Additional Comments From dnovillo at gcc dot gnu dot org  2005-02-01 
17:21 -------

Similar in nature to 19217 but in this case with flow sensitive aliasing.  We
visit a dead PHI which takes the address of several variables, but since it's
dead, the alias analyzer never sees it.

Since we mark foo_28 visited in the verifier, we then fail when we see that the
pointer has no points-to sets.  The immediate solution is to only mark a name
visited if we see it *used* in the IL, not just defined.

If the statement that uses the pointer is itself dead, this would still work
because the alias analyzer would've processed the pointer anyway.

Testing in progress.

Index: tree-ssa.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/tree-ssa.c,v
retrieving revision 2.73
diff -d -u -p -r2.73 tree-ssa.c
--- tree-ssa.c  24 Jan 2005 20:47:43 -0000      2.73
+++ tree-ssa.c  1 Feb 2005 17:21:14 -0000
@@ -108,8 +108,6 @@ flush_pending_stmts (edge e)
 static bool
 verify_ssa_name (tree ssa_name, bool is_virtual)
 {
-  TREE_VISITED (ssa_name) = 1;
-
   if (TREE_CODE (ssa_name) != SSA_NAME)
     {
       error ("Expected an SSA_NAME object");
@@ -219,6 +217,7 @@ verify_use (basic_block bb, basic_block
   bool err = false;

   err = verify_ssa_name (ssa_name, is_virtual);
+  TREE_VISITED (ssa_name) = 1;

   if (IS_EMPTY_STMT (SSA_NAME_DEF_STMT (ssa_name))
       && var_ann (SSA_NAME_VAR (ssa_name))->default_def == ssa_name)


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19670

Reply via email to