aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Analysis
diff options
context:
space:
mode:
authorDavid Chisnall <csdavec@swan.ac.uk>2012-04-06 17:27:41 +0000
committerDavid Chisnall <csdavec@swan.ac.uk>2012-04-06 17:27:41 +0000
commitb381578fcb5fea988f661dbbee9747b8fd55c5fb (patch)
tree7d93ff26b1e2a738d77e91edfc5443eb1c25949b /lib/Analysis
parent9ceebb7e92e980340d199b550e3a2110c80ea871 (diff)
downloadexternal_llvm-b381578fcb5fea988f661dbbee9747b8fd55c5fb.zip
external_llvm-b381578fcb5fea988f661dbbee9747b8fd55c5fb.tar.gz
external_llvm-b381578fcb5fea988f661dbbee9747b8fd55c5fb.tar.bz2
Reintroduce InlineCostAnalyzer::getInlineCost() variant with explicit callee
parameter until we have a more sensible API for doing the same thing. Reviewed by Chandler. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154180 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis')
-rw-r--r--lib/Analysis/InlineCost.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Analysis/InlineCost.cpp b/lib/Analysis/InlineCost.cpp
index 246e679..c4599c8 100644
--- a/lib/Analysis/InlineCost.cpp
+++ b/lib/Analysis/InlineCost.cpp
@@ -988,8 +988,11 @@ void CallAnalyzer::dump() {
}
InlineCost InlineCostAnalyzer::getInlineCost(CallSite CS, int Threshold) {
- Function *Callee = CS.getCalledFunction();
+ return getInlineCost(CS, CS.getCalledFunction(), Threshold);
+}
+InlineCost InlineCostAnalyzer::getInlineCost(CallSite CS, Function *Callee,
+ int Threshold) {
// Don't inline functions which can be redefined at link-time to mean
// something else. Don't inline functions marked noinline or call sites
// marked noinline.