diff options
author | Jeff Law <law@redhat.com> | 2015-10-23 16:34:04 -0600 |
---|---|---|
committer | Jeff Law <law@gcc.gnu.org> | 2015-10-23 16:34:04 -0600 |
commit | 9447d255f44d763533cd25ca464665fa806aeb66 (patch) | |
tree | 473ae624fa03edb8c9c84b07db7d569cedfa07f7 /gcc/passes.c | |
parent | 73a842690d16120be06aa3d29f4bd0077375c04a (diff) | |
download | gcc-9447d255f44d763533cd25ca464665fa806aeb66.zip gcc-9447d255f44d763533cd25ca464665fa806aeb66.tar.gz gcc-9447d255f44d763533cd25ca464665fa806aeb66.tar.bz2 |
[PATCH] Call flush_ssaname_freelist more often
[PATCH] Call flush_ssaname_freelist more often
* passes.c (execute_function_todo): Do not call flush_ssaname_freelist
here. Instead...
(execute_todo): Call it here.
* tree-ssanames.c (make_ssa_name_fn): Unconditionally gather reuse
statistics
(pass_release_ssa_names::execute): Do not call flusH_ssaname_freelist.
From-SVN: r229272
Diffstat (limited to 'gcc/passes.c')
-rw-r--r-- | gcc/passes.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/gcc/passes.c b/gcc/passes.c index 6ef6d2e..0d147fd 100644 --- a/gcc/passes.c +++ b/gcc/passes.c @@ -1919,14 +1919,6 @@ execute_function_todo (function *fn, void *data) { cleanup_tree_cfg (); - /* Once unreachable nodes have been removed from the CFG, - there can't be any lingering references to released - SSA_NAMES (because there is no more unreachable code). - - Thus, now is the time to flush the SSA_NAMEs freelist. */ - if (fn->gimple_df) - flush_ssaname_freelist (); - /* When cleanup_tree_cfg merges consecutive blocks, it may perform some simplistic propagation when removing single valued PHI nodes. This propagation may, in turn, cause the @@ -2032,6 +2024,11 @@ execute_todo (unsigned int flags) if (flags) do_per_function (execute_function_todo, (void *)(size_t) flags); + /* At this point we should not have any unreachable code in the + CFG, so it is safe to flush the pending freelist for SSA_NAMES. */ + if (cfun && cfun->gimple_df) + flush_ssaname_freelist (); + /* Always remove functions just as before inlining: IPA passes might be interested to see bodies of extern inline functions that are not inlined to analyze side effects. The full removal is done just at the end |