diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2010-10-20 17:30:10 +0000 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2010-10-20 17:30:10 +0000 |
commit | 4244a86e669bb667e282329e6c1015de56ead9ea (patch) | |
tree | 9c6c6e3782229c6edf56d2ac2df6aeed1adedbeb /gcc/tree-optimize.c | |
parent | 825cb171c0e5482e873a53af0982346947302a9c (diff) | |
download | gcc-4244a86e669bb667e282329e6c1015de56ead9ea.zip gcc-4244a86e669bb667e282329e6c1015de56ead9ea.tar.gz gcc-4244a86e669bb667e282329e6c1015de56ead9ea.tar.bz2 |
tree-optimize.c (execute_fixup_cfg): Purge dead abnormal call edges if there is a call statement to pure or const...
* tree-optimize.c (execute_fixup_cfg): Purge dead abnormal call edges
if there is a call statement to pure or const function in the block.
From-SVN: r165730
Diffstat (limited to 'gcc/tree-optimize.c')
-rw-r--r-- | gcc/tree-optimize.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/tree-optimize.c b/gcc/tree-optimize.c index 9b4973f..f5a35ad 100644 --- a/gcc/tree-optimize.c +++ b/gcc/tree-optimize.c @@ -271,13 +271,16 @@ execute_fixup_cfg (void) int flags = gimple_call_flags (stmt); if (flags & (ECF_CONST | ECF_PURE | ECF_LOOPING_CONST_OR_PURE)) { + if (gimple_purge_dead_abnormal_call_edges (bb)) + todo |= TODO_cleanup_cfg; + if (gimple_in_ssa_p (cfun)) { todo |= TODO_update_ssa | TODO_cleanup_cfg; update_stmt (stmt); } } - + if (flags & ECF_NORETURN && fixup_noreturn_call (stmt)) todo |= TODO_cleanup_cfg; |