summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGDebugInfo.cpp
diff options
context:
space:
mode:
authorFedor Sergeev <fedor.sergeev@azul.com>2019-06-26 13:24:24 +0000
committerFedor Sergeev <fedor.sergeev@azul.com>2019-06-26 13:24:24 +0000
commit1a3dc761860d620ac8ed7e32a4285952142f780b (patch)
treeb290d2280cfc3f4b9be36e7de9fcdc1bfc186134 /clang/lib/CodeGen/CGDebugInfo.cpp
parent09bc66576600d06ce5cbcd55731f04a93adfdcfd (diff)
downloadbcm5719-llvm-1a3dc761860d620ac8ed7e32a4285952142f780b.tar.gz
bcm5719-llvm-1a3dc761860d620ac8ed7e32a4285952142f780b.zip
[InlineCost] cleanup calculations of Cost and Threshold
Summary: Doing better separation of Cost and Threshold. Cost counts the abstract complexity of live instructions, while Threshold is an upper bound of complexity that inlining is comfortable to pay. There are two parts: - huge 15K last-call-to-static bonus is no longer subtracted from Cost but rather is now added to Threshold. That makes much more sense, as the cost of inlining (Cost) is not changed by the fact that internal function is called once. It only changes the likelyhood of this inlining being profitable (Threshold). - bonus for calls proved-to-be-inlinable into callee is no longer subtracted from Cost but added to Threshold instead. While calculations are somewhat different, overall InlineResult should stay the same since Cost >= Threshold compares the same. Reviewers: eraman, greened, chandlerc, yrouban, apilipenko Reviewed By: apilipenko Tags: #llvm Differential Revision: https://reviews.llvm.org/D60740 llvm-svn: 364422
Diffstat (limited to 'clang/lib/CodeGen/CGDebugInfo.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud