summaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2012-04-05 09:45:18 +0000
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2012-04-05 09:45:18 +0000
commitbc8a845124e70791b09bfed19673997a4c165f5f (patch)
tree82a4f09ff51f17c39f508dc9425bc833499b68fd /gcc
parent13ff78a491d6e5166f838c74bd377ad4d2ed81b6 (diff)
downloadgcc-bc8a845124e70791b09bfed19673997a4c165f5f.tar.gz
2012-04-05 Richard Guenther <rguenther@suse.de>
* tree-nrv.c (tree_nrv): Release VDEFs. * tree-sra.c (sra_modify_constructor_assign): Likewise. (sra_modify_assign): Likewise. * tree-vect-stmts.c (vect_remove_stores): Likewise. * tree-vect-loop.c (vect_transform_loop): Likewise. * tree-ssa-dom.c (optimize_stmt): Likewise. * tree-vect-slp.c (vect_schedule_slp): Likewise. * tree-ssa-math-opts.c (execute_cse_sincos): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186160 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog11
-rw-r--r--gcc/tree-eh.c4
-rw-r--r--gcc/tree-nrv.c1
-rw-r--r--gcc/tree-sra.c4
-rw-r--r--gcc/tree-ssa-dom.c1
-rw-r--r--gcc/tree-ssa-math-opts.c6
-rw-r--r--gcc/tree-vect-loop.c5
-rw-r--r--gcc/tree-vect-slp.c2
-rw-r--r--gcc/tree-vect-stmts.c2
9 files changed, 33 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 591c5af93ca..bd45eb75729 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,16 @@
2012-04-05 Richard Guenther <rguenther@suse.de>
+ * tree-nrv.c (tree_nrv): Release VDEFs.
+ * tree-sra.c (sra_modify_constructor_assign): Likewise.
+ (sra_modify_assign): Likewise.
+ * tree-vect-stmts.c (vect_remove_stores): Likewise.
+ * tree-vect-loop.c (vect_transform_loop): Likewise.
+ * tree-ssa-dom.c (optimize_stmt): Likewise.
+ * tree-vect-slp.c (vect_schedule_slp): Likewise.
+ * tree-ssa-math-opts.c (execute_cse_sincos): Likewise.
+
+2012-04-05 Richard Guenther <rguenther@suse.de>
+
* gimple-iterator.c (gsi_remove): Return whether EH edges need to be
cleanup.
* gimple.h (gsi_remove): Adjust.
diff --git a/gcc/tree-eh.c b/gcc/tree-eh.c
index f19dc2cdffb..b78d9e9bd3a 100644
--- a/gcc/tree-eh.c
+++ b/gcc/tree-eh.c
@@ -3268,12 +3268,12 @@ sink_clobbers (basic_block bb)
vdef = gimple_vdef (stmt);
if (vdef && TREE_CODE (vdef) == SSA_NAME)
{
+ release_ssa_name (vdef);
vdef = SSA_NAME_VAR (vdef);
mark_sym_for_renaming (vdef);
gimple_set_vdef (stmt, vdef);
gimple_set_vuse (stmt, vdef);
}
- release_defs (stmt);
gsi_insert_before (&dgsi, stmt, GSI_SAME_STMT);
}
@@ -3955,7 +3955,7 @@ cleanup_empty_eh_move_lp (basic_block bb, edge e_out,
/* Delete the RESX that was matched within the empty handler block. */
gsi = gsi_last_bb (bb);
- mark_virtual_ops_for_renaming (gsi_stmt (gsi));
+ unlink_stmt_vdef (gsi_stmt (gsi));
gsi_remove (&gsi, true);
/* Clean up E_OUT for the fallthru. */
diff --git a/gcc/tree-nrv.c b/gcc/tree-nrv.c
index 982fcc8fc11..9176e29c3ad 100644
--- a/gcc/tree-nrv.c
+++ b/gcc/tree-nrv.c
@@ -244,6 +244,7 @@ tree_nrv (void)
{
unlink_stmt_vdef (stmt);
gsi_remove (&gsi, true);
+ release_defs (stmt);
}
else
{
diff --git a/gcc/tree-sra.c b/gcc/tree-sra.c
index 84dc3be27c8..c5f105a2297 100644
--- a/gcc/tree-sra.c
+++ b/gcc/tree-sra.c
@@ -2821,6 +2821,7 @@ sra_modify_constructor_assign (gimple *stmt, gimple_stmt_iterator *gsi)
{
unlink_stmt_vdef (*stmt);
gsi_remove (gsi, true);
+ release_defs (*stmt);
return SRA_AM_REMOVED;
}
else
@@ -2844,6 +2845,7 @@ sra_modify_constructor_assign (gimple *stmt, gimple_stmt_iterator *gsi)
init_subtree_with_zero (acc, gsi, false, loc);
unlink_stmt_vdef (*stmt);
gsi_remove (gsi, true);
+ release_defs (*stmt);
return SRA_AM_REMOVED;
}
else
@@ -3094,6 +3096,7 @@ sra_modify_assign (gimple *stmt, gimple_stmt_iterator *gsi)
gsi_next (gsi);
unlink_stmt_vdef (*stmt);
gsi_remove (&orig_gsi, true);
+ release_defs (*stmt);
sra_stats.deleted++;
return SRA_AM_REMOVED;
}
@@ -3114,6 +3117,7 @@ sra_modify_assign (gimple *stmt, gimple_stmt_iterator *gsi)
gcc_assert (*stmt == gsi_stmt (*gsi));
unlink_stmt_vdef (*stmt);
gsi_remove (gsi, true);
+ release_defs (*stmt);
sra_stats.deleted++;
return SRA_AM_REMOVED;
}
diff --git a/gcc/tree-ssa-dom.c b/gcc/tree-ssa-dom.c
index d2e4cc4b0b3..d35297abbd7 100644
--- a/gcc/tree-ssa-dom.c
+++ b/gcc/tree-ssa-dom.c
@@ -2301,6 +2301,7 @@ optimize_stmt (basic_block bb, gimple_stmt_iterator si)
if (dump_file && (dump_flags & TDF_DETAILS))
fprintf (dump_file, " Flagged to clear EH edges.\n");
}
+ release_defs (stmt);
return;
}
}
diff --git a/gcc/tree-ssa-math-opts.c b/gcc/tree-ssa-math-opts.c
index 5c3543ecf39..f54d08dffee 100644
--- a/gcc/tree-ssa-math-opts.c
+++ b/gcc/tree-ssa-math-opts.c
@@ -1430,6 +1430,8 @@ execute_cse_sincos (void)
gimple_set_location (new_stmt, loc);
unlink_stmt_vdef (stmt);
gsi_replace (&gsi, new_stmt, true);
+ if (gimple_vdef (stmt))
+ release_ssa_name (gimple_vdef (stmt));
}
break;
@@ -1450,6 +1452,8 @@ execute_cse_sincos (void)
gimple_set_location (new_stmt, loc);
unlink_stmt_vdef (stmt);
gsi_replace (&gsi, new_stmt, true);
+ if (gimple_vdef (stmt))
+ release_ssa_name (gimple_vdef (stmt));
}
break;
@@ -1465,6 +1469,8 @@ execute_cse_sincos (void)
gimple_set_location (new_stmt, loc);
unlink_stmt_vdef (stmt);
gsi_replace (&gsi, new_stmt, true);
+ if (gimple_vdef (stmt))
+ release_ssa_name (gimple_vdef (stmt));
}
break;
diff --git a/gcc/tree-vect-loop.c b/gcc/tree-vect-loop.c
index 16515dce10d..3df0e4b61ba 100644
--- a/gcc/tree-vect-loop.c
+++ b/gcc/tree-vect-loop.c
@@ -5476,8 +5476,11 @@ vect_transform_loop (loop_vec_info loop_vinfo)
else
{
/* Free the attached stmt_vec_info and remove the stmt. */
- free_stmt_vec_info (gsi_stmt (si));
+ gimple store = gsi_stmt (si);
+ free_stmt_vec_info (store);
+ unlink_stmt_vdef (store);
gsi_remove (&si, true);
+ release_defs (store);
continue;
}
}
diff --git a/gcc/tree-vect-slp.c b/gcc/tree-vect-slp.c
index 0ab6be0671a..014fa988722 100644
--- a/gcc/tree-vect-slp.c
+++ b/gcc/tree-vect-slp.c
@@ -3043,7 +3043,9 @@ vect_schedule_slp (loop_vec_info loop_vinfo, bb_vec_info bb_vinfo)
store = STMT_VINFO_RELATED_STMT (vinfo_for_stmt (store));
/* Free the attached stmt_vec_info and remove the stmt. */
gsi = gsi_for_stmt (store);
+ unlink_stmt_vdef (store);
gsi_remove (&gsi, true);
+ release_defs (store);
free_stmt_vec_info (store);
}
}
diff --git a/gcc/tree-vect-stmts.c b/gcc/tree-vect-stmts.c
index acaf6757a78..dabb63d7a92 100644
--- a/gcc/tree-vect-stmts.c
+++ b/gcc/tree-vect-stmts.c
@@ -5653,7 +5653,9 @@ vect_remove_stores (gimple first_stmt)
next = STMT_VINFO_RELATED_STMT (stmt_info);
/* Free the attached stmt_vec_info and remove the stmt. */
next_si = gsi_for_stmt (next);
+ unlink_stmt_vdef (next);
gsi_remove (&next_si, true);
+ release_defs (next);
free_stmt_vec_info (next);
next = tmp;
}