projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3b32d02
)
Change condition for determining whether a function is small for inlining metrics...
author
Eli Friedman
<eli.friedman@gmail.com>
Tue, 24 May 2011 20:22:24 +0000
(20:22 +0000)
committer
Eli Friedman
<eli.friedman@gmail.com>
Tue, 24 May 2011 20:22:24 +0000
(20:22 +0000)
with few basic blocks are not re-analyzed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131994
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Analysis/InlineCost.cpp
patch
|
blob
|
history
diff --git
a/lib/Analysis/InlineCost.cpp
b/lib/Analysis/InlineCost.cpp
index 9ea34959b998e27a29ec9bf2bdb75af39d55d8f1..efde5984c1157a069eb49dddcd37e1e94b95958a 100644
(file)
--- a/
lib/Analysis/InlineCost.cpp
+++ b/
lib/Analysis/InlineCost.cpp
@@
-593,7
+593,7
@@
InlineCostAnalyzer::growCachedCostInfo(Function *Caller, Function *Callee) {
CodeMetrics &CallerMetrics = CachedFunctionInfo[Caller].Metrics;
// For small functions we prefer to recalculate the cost for better accuracy.
- if (CallerMetrics.NumBlocks < 10
||
CallerMetrics.NumInsts < 1000) {
+ if (CallerMetrics.NumBlocks < 10
&&
CallerMetrics.NumInsts < 1000) {
resetCachedCostInfo(Caller);
return;
}