Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 4 additions & 5 deletions bolt/lib/Passes/PettisAndHansen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,11 +143,10 @@ std::vector<Cluster> pettisAndHansen(const CallGraph &Cg) {
// Find an arc with max weight and merge its nodes

while (!Carcs.empty()) {
auto Maxpos =
std::max_element(Carcs.begin(), Carcs.end(),
[&](const ClusterArc &Carc1, const ClusterArc &Carc2) {
return Carc1.Weight < Carc2.Weight;
});
auto Maxpos = llvm::max_element(
Carcs, [&](const ClusterArc &Carc1, const ClusterArc &Carc2) {
return Carc1.Weight < Carc2.Weight;
});

ClusterArc Max = *Maxpos;
Carcs.erase(Maxpos);
Expand Down
Loading