[llvm] 59127de - [NFC][GCOV] Fix build: there's `llvm::stable_partition()` wrapper
Roman Lebedev via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 5 12:52:53 PDT 2020
Author: Roman Lebedev
Date: 2020-10-05T22:52:32+03:00
New Revision: 59127de2435b54c6b1621f5b3e7fabc3e79ff248
URL: https://github.com/llvm/llvm-project/commit/59127de2435b54c6b1621f5b3e7fabc3e79ff248
DIFF: https://github.com/llvm/llvm-project/commit/59127de2435b54c6b1621f5b3e7fabc3e79ff248.diff
LOG: [NFC][GCOV] Fix build: there's `llvm::stable_partition()` wrapper
Added:
Modified:
llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp b/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp
index fad1ba093acf..527644a69d91 100644
--- a/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp
+++ b/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp
@@ -884,8 +884,9 @@ bool GCOVProfiler::emitProfileNotes(
return E->Removed || (!E->InMST && !E->Place);
});
const size_t Measured =
- llvm::stable_partition(
- MST.AllEdges, [](std::unique_ptr<Edge> &E) { return E->Place; }) -
+ std::stable_partition(
+ MST.AllEdges.begin(), MST.AllEdges.end(),
+ [](std::unique_ptr<Edge> &E) { return E->Place; }) -
MST.AllEdges.begin();
for (size_t I : llvm::seq<size_t>(0, Measured)) {
Edge &E = *MST.AllEdges[I];
More information about the llvm-commits
mailing list