[llvm-exegesis] Use range-based for loops (NFC)
This commit is contained in:
parent
8a2d68f6be
commit
c7b25faaac
@ -307,10 +307,8 @@ void BenchmarkClustering::stabilize(unsigned NumOpcodes) {
|
||||
assert(std::distance(it, OldCluster.PointIndices.end()) > 0 &&
|
||||
"Should have found at least one bad point");
|
||||
// Mark to-be-moved points as belonging to the new cluster.
|
||||
std::for_each(it, OldCluster.PointIndices.end(),
|
||||
[this, &UnstableCluster](size_t P) {
|
||||
ClusterIdForPoint_[P] = UnstableCluster.Id;
|
||||
});
|
||||
for (size_t P : llvm::make_range(it, OldCluster.PointIndices.end()))
|
||||
ClusterIdForPoint_[P] = UnstableCluster.Id;
|
||||
// Actually append to-be-moved points to the new cluster.
|
||||
UnstableCluster.PointIndices.insert(UnstableCluster.PointIndices.end(),
|
||||
it, OldCluster.PointIndices.end());
|
||||
|
@ -503,11 +503,8 @@ void benchmarkMain() {
|
||||
}
|
||||
|
||||
BitVector AllReservedRegs;
|
||||
llvm::for_each(Repetitors,
|
||||
[&AllReservedRegs](
|
||||
const std::unique_ptr<const SnippetRepetitor> &Repetitor) {
|
||||
AllReservedRegs |= Repetitor->getReservedRegs();
|
||||
});
|
||||
for (const std::unique_ptr<const SnippetRepetitor> &Repetitor : Repetitors)
|
||||
AllReservedRegs |= Repetitor->getReservedRegs();
|
||||
|
||||
std::vector<BenchmarkCode> Configurations;
|
||||
if (!Opcodes.empty()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user