summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorFangrui Song <maskray@google.com>2019-04-19 05:49:29 +0000
committerFangrui Song <maskray@google.com>2019-04-19 05:49:29 +0000
commit82216048e6bcdf2e37b356e45954ac8cdceaab50 (patch)
tree4608c1566b2d6edd44da907707ce31075d89ba08 /llvm/lib
parentbb769a29467b51c391a0149ea7301e71c0569a71 (diff)
downloadbcm5719-llvm-82216048e6bcdf2e37b356e45954ac8cdceaab50.tar.gz
bcm5719-llvm-82216048e6bcdf2e37b356e45954ac8cdceaab50.zip
[MergeFunc] Use less_first() as the comparator of Schwartzian transform
llvm-svn: 358738
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Transforms/IPO/MergeFunctions.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/llvm/lib/Transforms/IPO/MergeFunctions.cpp b/llvm/lib/Transforms/IPO/MergeFunctions.cpp
index d0c16138f9e..8a40f0479f2 100644
--- a/llvm/lib/Transforms/IPO/MergeFunctions.cpp
+++ b/llvm/lib/Transforms/IPO/MergeFunctions.cpp
@@ -403,12 +403,7 @@ bool MergeFunctions::runOnModule(Module &M) {
}
}
- std::stable_sort(
- HashedFuncs.begin(), HashedFuncs.end(),
- [](const std::pair<FunctionComparator::FunctionHash, Function *> &a,
- const std::pair<FunctionComparator::FunctionHash, Function *> &b) {
- return a.first < b.first;
- });
+ std::stable_sort(HashedFuncs.begin(), HashedFuncs.end(), less_first());
auto S = HashedFuncs.begin();
for (auto I = HashedFuncs.begin(), IE = HashedFuncs.end(); I != IE; ++I) {
OpenPOWER on IntegriCloud