summaryrefslogtreecommitdiff
path: root/lib/CodeGen/PostRASchedulerList.cpp
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2009-09-06 12:10:17 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2009-09-06 12:10:17 +0000
commitbe441c0f348a1c02a3632718832f6e2d42c4f8f0 (patch)
treef345bce608eb9aa8b3afd387b9f93d6e20df543f /lib/CodeGen/PostRASchedulerList.cpp
parent8ecbe8d974e1c1f778207b87dcdf887060f5c699 (diff)
downloadllvm-be441c0f348a1c02a3632718832f6e2d42c4f8f0.tar.gz
llvm-be441c0f348a1c02a3632718832f6e2d42c4f8f0.tar.bz2
llvm-be441c0f348a1c02a3632718832f6e2d42c4f8f0.tar.xz
It's a bool, so treat it like one. Fixes a MSVC warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81112 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/PostRASchedulerList.cpp')
-rw-r--r--lib/CodeGen/PostRASchedulerList.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/CodeGen/PostRASchedulerList.cpp b/lib/CodeGen/PostRASchedulerList.cpp
index f487bd5d7b..e1491256fe 100644
--- a/lib/CodeGen/PostRASchedulerList.cpp
+++ b/lib/CodeGen/PostRASchedulerList.cpp
@@ -987,7 +987,7 @@ void SchedulePostRATDList::ListScheduleTopDown() {
// In any cycle where we can't schedule any instructions, we must
// stall or emit a noop, depending on the target.
- bool CycleInstCnt = 0;
+ bool CycleHasInsts = false;
// While Available queue is not empty, grab the node with the highest
// priority. If it is not ready put it back. Schedule the node.
@@ -1045,7 +1045,7 @@ void SchedulePostRATDList::ListScheduleTopDown() {
if (FoundSUnit) {
ScheduleNodeTopDown(FoundSUnit, CurCycle);
HazardRec->EmitInstruction(FoundSUnit);
- CycleInstCnt++;
+ CycleHasInsts = true;
// If we are using the target-specific hazards, then don't
// advance the cycle time just because we schedule a node. If
@@ -1056,7 +1056,7 @@ void SchedulePostRATDList::ListScheduleTopDown() {
++CurCycle;
}
} else {
- if (CycleInstCnt > 0) {
+ if (CycleHasInsts) {
DEBUG(errs() << "*** Finished cycle " << CurCycle << '\n');
HazardRec->AdvanceCycle();
} else if (!HasNoopHazards) {
@@ -1076,7 +1076,7 @@ void SchedulePostRATDList::ListScheduleTopDown() {
}
++CurCycle;
- CycleInstCnt = 0;
+ CycleHasInsts = false;
}
}