[llvm] 907d4e7 - [llvm-exegesis] Analysis.cpp - use for-range loop. NFCI.
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 19 04:56:25 PDT 2021
Author: Simon Pilgrim
Date: 2021-04-19T12:56:10+01:00
New Revision: 907d4e754e3180b2ce2bb56ab6aefaac11338ced
URL: https://github.com/llvm/llvm-project/commit/907d4e754e3180b2ce2bb56ab6aefaac11338ced
DIFF: https://github.com/llvm/llvm-project/commit/907d4e754e3180b2ce2bb56ab6aefaac11338ced.diff
LOG: [llvm-exegesis] Analysis.cpp - use for-range loop. NFCI.
Added:
Modified:
llvm/tools/llvm-exegesis/lib/Analysis.cpp
Removed:
################################################################################
diff --git a/llvm/tools/llvm-exegesis/lib/Analysis.cpp b/llvm/tools/llvm-exegesis/lib/Analysis.cpp
index a1f576db45000..087100d3d1223 100644
--- a/llvm/tools/llvm-exegesis/lib/Analysis.cpp
+++ b/llvm/tools/llvm-exegesis/lib/Analysis.cpp
@@ -198,9 +198,8 @@ Error Analysis::run<Analysis::PrintClusters>(raw_ostream &OS) const {
OS << "\n";
// Write the points.
- const auto &Clusters = Clustering_.getValidClusters();
- for (size_t I = 0, E = Clusters.size(); I < E; ++I) {
- for (const size_t PointId : Clusters[I].PointIndices) {
+ for (const auto &ClusterIt : Clustering_.getValidClusters()) {
+ for (const size_t PointId : ClusterIt.PointIndices) {
printInstructionRowCsv(PointId, OS);
}
OS << "\n\n";
More information about the llvm-commits
mailing list