This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[tuples][patch] Moving variable declaration to the top of the block
- From: "Oleg Ryjkov" <olegr at google dot com>
- To: gcc-patches at gcc dot gnu dot org
- Cc: "Diego Novillo" <dnovillo at google dot com>, "Bill Maddox" <maddox at google dot com>
- Date: Tue, 15 Apr 2008 12:58:57 -0700
- Subject: [tuples][patch] Moving variable declaration to the top of the block
Hi,
Its the same problem that I had to fix in my previous patch. A
variable is declared below gcc_assert. This patch fixes it.
Oleg
2008-04-15 Oleg Ryjkov <olegr@google.com>
* tree-ssa-dom.c (record_const_or_copy): Moving a variable
declaration to
the top of a block.
Index: tree-ssa-dom.c
===================================================================
--- tree-ssa-dom.c (revision 134323)
+++ tree-ssa-dom.c (working copy)
@@ -1491,10 +1491,10 @@ loop_depth_of_name (tree x)
static void
record_const_or_copy (tree x, tree y)
{
- gcc_assert (TREE_CODE (x) == SSA_NAME);
-
tree prev_x = SSA_NAME_VALUE (x);
+ gcc_assert (TREE_CODE (x) == SSA_NAME);
+
if (TREE_CODE (y) == SSA_NAME)
{
tree tmp = SSA_NAME_VALUE (y);
Index: ChangeLog.tuples
===================================================================
--- ChangeLog.tuples (revision 134323)
+++ ChangeLog.tuples (working copy)
@@ -1,3 +1,8 @@
+2008-04-15 Oleg Ryjkov <olegr@google.com>
+
+ * tree-ssa-dom.c (record_const_or_copy): Moving a variable declaration to
+ the top of a block.
+
2008-04-15 Doug Kwan <dougkwan@google.com>
* tree-ssa-sink.c (File): Uncomment all previously disabled code.