aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/resolve
diff options
context:
space:
mode:
authorMartin Jambor <mjambor@suse.cz>2022-12-14 00:33:05 +0100
committerMartin Jambor <mjambor@suse.cz>2022-12-14 00:58:04 +0100
commit095a13eda2caf6842096a3ab78b2081c50fe8799 (patch)
tree73a562808c17c1eead358c859b570fade212cae8 /gcc/rust/resolve
parent4834e9360f7bf42fbeabaa20de5619e67c9fee4e (diff)
downloadgcc-095a13eda2caf6842096a3ab78b2081c50fe8799.zip
gcc-095a13eda2caf6842096a3ab78b2081c50fe8799.tar.gz
gcc-095a13eda2caf6842096a3ab78b2081c50fe8799.tar.bz2
ipa-cp: Leave removal of unused parameters to IPA-SRA
Looking at some benchmarks I have noticed many cases when IPA-CP cloned a function for all contexts just because it knew that some parameters were not used at all. Then IPA-SRA looked at the function and cloned it again to split another parameter or two. The latter pass is better equipped to detect when parameters can be altogether removed and so the IPA-CP cloning was for no good reason. This patch simply alters the IPA-CP not to do that in the situations where IPA-SRA can (for nodes which can be made local) with additional dumping requested by Honza. gcc/ChangeLog: 2022-12-13 Martin Jambor <mjambor@suse.cz> * ipa-cp.cc (clone_for_param_removal_p): New function. (estimate_local_effects): Call it before considering cloning just to remove unused parameters.
Diffstat (limited to 'gcc/rust/resolve')
0 files changed, 0 insertions, 0 deletions