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:
0e33d9f
)
Make the swap code here a bit more obvious what its doing... We're
author
Chandler Carruth
<chandlerc@gmail.com>
Thu, 15 Mar 2012 00:55:51 +0000
(
00:55
+0000)
committer
Chandler Carruth
<chandlerc@gmail.com>
Thu, 15 Mar 2012 00:55:51 +0000
(
00:55
+0000)
essentially sorting the pair's arguments. I'd love to actually call sort
here, but I'm just not that crazy. ;]
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152764
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 37aa729552bc2197dd2ba5592c29118a5887f866..3754e923cebc3b8ac87fce8d8870041e1f05ee09 100644
(file)
--- a/
lib/Analysis/InlineCost.cpp
+++ b/
lib/Analysis/InlineCost.cpp
@@
-435,7
+435,7
@@
void InlineCostAnalyzer::FunctionInfo::countCodeReductionForPointerPair(
if (ArgIt == PointerArgs.end())
continue;
std::pair<unsigned, unsigned> ArgPair(ArgIt->second, ArgIdx);
- if (Arg
It->second > ArgIdx
)
+ if (Arg
Pair.first > ArgPair.second
)
std::swap(ArgPair.first, ArgPair.second);
PointerArgPairWeights[ArgPair]