aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp
diff options
context:
space:
mode:
authorKazu Hirata <kazu@google.com>2021-12-06 08:49:10 -0800
committerKazu Hirata <kazu@google.com>2021-12-06 08:49:10 -0800
commitc4a8928b51daa486013abbfa4dad75def2a9528e (patch)
treea47955bbcc57b103e80cabcc6bd59f5beb0f4cd0 /llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp
parenta05a0c3c2f8eefc80d84b7a87a23a4452d4a3087 (diff)
downloadllvm-c4a8928b51daa486013abbfa4dad75def2a9528e.zip
llvm-c4a8928b51daa486013abbfa4dad75def2a9528e.tar.gz
llvm-c4a8928b51daa486013abbfa4dad75def2a9528e.tar.bz2
[CodeGen] Use range-based for loops (NFC)
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp b/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp
index 540a6e3..1094047 100644
--- a/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGVLIW.cpp
@@ -169,11 +169,11 @@ void ScheduleDAGVLIW::listScheduleTopDown() {
releaseSuccessors(&EntrySU);
// All leaves to AvailableQueue.
- for (unsigned i = 0, e = SUnits.size(); i != e; ++i) {
+ for (SUnit &SU : SUnits) {
// It is available if it has no predecessors.
- if (SUnits[i].Preds.empty()) {
- AvailableQueue->push(&SUnits[i]);
- SUnits[i].isAvailable = true;
+ if (SU.Preds.empty()) {
+ AvailableQueue->push(&SU);
+ SU.isAvailable = true;
}
}