summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatz <matz@138bc75d-0d04-0410-961f-82ee72b054a4>2009-04-26 19:24:16 +0000
committermatz <matz@138bc75d-0d04-0410-961f-82ee72b054a4>2009-04-26 19:24:16 +0000
commit0d3f8fd56e7872cb86a14f89a91ce7a781f93475 (patch)
treeb8f137fd4c9613bd54aa4345bda23480a00c92f6
parentabe2d6dd80e07fc55a69dd3da361d78436222044 (diff)
downloadgcc-0d3f8fd56e7872cb86a14f89a91ce7a781f93475.tar.gz
* tree-ssa-copyrename.c (rename_ssa_copies): Don't iterate
beyond num_ssa_names. * tree-ssa-ter.c (free_temp_expr_table): Likewise. * tree-ssa-coalesce.c (create_outofssa_var_map): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@146815 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog7
-rw-r--r--gcc/tree-ssa-coalesce.c2
-rw-r--r--gcc/tree-ssa-copyrename.c4
-rw-r--r--gcc/tree-ssa-ter.c2
4 files changed, 11 insertions, 4 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index ee80aa045d3..fab18b1f99a 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,10 @@
+2009-04-26 Michael Matz <matz@suse.de>
+
+ * tree-ssa-copyrename.c (rename_ssa_copies): Don't iterate
+ beyond num_ssa_names.
+ * tree-ssa-ter.c (free_temp_expr_table): Likewise.
+ * tree-ssa-coalesce.c (create_outofssa_var_map): Likewise.
+
2009-04-26 Jakub Jelinek <jakub@redhat.com>
PR inline-asm/39543
diff --git a/gcc/tree-ssa-coalesce.c b/gcc/tree-ssa-coalesce.c
index 97f9f409989..9f7bafda46d 100644
--- a/gcc/tree-ssa-coalesce.c
+++ b/gcc/tree-ssa-coalesce.c
@@ -974,7 +974,7 @@ create_outofssa_var_map (coalesce_list_p cl, bitmap used_in_copy)
used_in_virtual_ops = BITMAP_ALLOC (NULL);
#endif
- map = init_var_map (num_ssa_names + 1);
+ map = init_var_map (num_ssa_names);
FOR_EACH_BB (bb)
{
diff --git a/gcc/tree-ssa-copyrename.c b/gcc/tree-ssa-copyrename.c
index e89824f74f9..38cd5493592 100644
--- a/gcc/tree-ssa-copyrename.c
+++ b/gcc/tree-ssa-copyrename.c
@@ -291,7 +291,7 @@ rename_ssa_copies (void)
else
debug = NULL;
- map = init_var_map (num_ssa_names + 1);
+ map = init_var_map (num_ssa_names);
FOR_EACH_BB (bb)
{
@@ -339,7 +339,7 @@ rename_ssa_copies (void)
/* Now one more pass to make all elements of a partition share the same
root variable. */
- for (x = 1; x <= num_ssa_names; x++)
+ for (x = 1; x < num_ssa_names; x++)
{
part_var = partition_to_var (map, x);
if (!part_var)
diff --git a/gcc/tree-ssa-ter.c b/gcc/tree-ssa-ter.c
index b415971a243..6fd7ca14485 100644
--- a/gcc/tree-ssa-ter.c
+++ b/gcc/tree-ssa-ter.c
@@ -225,7 +225,7 @@ free_temp_expr_table (temp_expr_table_p t)
unsigned x;
for (x = 0; x <= num_var_partitions (t->map); x++)
gcc_assert (!t->kill_list[x]);
- for (x = 0; x < num_ssa_names + 1; x++)
+ for (x = 0; x < num_ssa_names; x++)
{
gcc_assert (t->expr_decl_uids[x] == NULL);
gcc_assert (t->partition_dependencies[x] == NULL);