re PR tree-optimization/22531 (ICE in mark_sym_for_renaming while compiling dwarf2out.c)
authorDaniel Berlin <dberlin@dberlin.org>
Sun, 17 Jul 2005 22:28:19 +0000 (22:28 +0000)
committerDaniel Berlin <dberlin@gcc.gnu.org>
Sun, 17 Jul 2005 22:28:19 +0000 (22:28 +0000)
2005-07-17  Daniel Berlin  <dberlin@dberlin.org>

Fix PR tree-optimization/22531
* tree-ssa-pre.c (do_eustores):  Make sure LHS is a decl for the
 moment.

From-SVN: r102119

gcc/ChangeLog
gcc/testsuite/gcc.c-torture/compile/pr22531.c [new file with mode: 0644]
gcc/tree-ssa-pre.c

index 3cde015f6be96d5c8f0a95fa5e68e13f87f0240e..f5896dabcd1614d687dc4f3265a92948eb21b162 100644 (file)
@@ -1,3 +1,9 @@
+2005-07-17  Daniel Berlin  <dberlin@dberlin.org>
+
+       Fix PR tree-optimization/22531
+       * tree-ssa-pre.c (do_eustores):  Make sure LHS is a decl for the
+        moment.
+
 2005-07-17  Daniel Berlin  <dberlin@dberlin.org>
 
        * tree-promote-statics.c (pass_promote_statics): Change dump file
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr22531.c b/gcc/testsuite/gcc.c-torture/compile/pr22531.c
new file mode 100644 (file)
index 0000000..70e2df7
--- /dev/null
@@ -0,0 +1,7 @@
+typedef struct dw_cfi_oprnd_struct {
+      unsigned long reg;
+} dw_cfa_location;
+void def_cfa_1 (void) {
+      dw_cfa_location loc;
+        loc.reg = loc.reg;
+}
index 67bc6d4dd5813ca19d106040be39ed8fb09309dd..d83b5e4b1265271ece0158dc2295069babde0fdb 100644 (file)
@@ -2807,6 +2807,7 @@ do_eustores (void)
 
              if (NUM_SSA_OPERANDS (found, SSA_OP_VUSE) != 1
                  || VUSE_OP (VUSE_OPS (found)) != kill
+                 || !DECL_P (TREE_OPERAND (stmt, 0))
                  || !operand_equal_p (TREE_OPERAND (found, 1), 
                                       TREE_OPERAND (stmt, 0), 0))
                {