aboutsummaryrefslogtreecommitdiff
path: root/lib/Target/ARM/ARMHazardRecognizer.cpp
diff options
context:
space:
mode:
authorAndrew Trick <atrick@apple.com>2010-12-08 20:04:29 +0000
committerAndrew Trick <atrick@apple.com>2010-12-08 20:04:29 +0000
commit6b1207267f01877ff9b351786c902cb2ecd354c0 (patch)
tree8a830ff262d3e13ca871ea01b172ff8e5583a238 /lib/Target/ARM/ARMHazardRecognizer.cpp
parentcd466f582aa83074294ab1a31b26eedd5a2fd025 (diff)
Generalize PostRAHazardRecognizer so it can be used in any pass for
both forward and backward scheduling. Rename it to ScoreboardHazardRecognizer (Scoreboard is one word). Remove integer division from the scoreboard's critical path. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121274 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/ARMHazardRecognizer.cpp')
-rw-r--r--lib/Target/ARM/ARMHazardRecognizer.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/lib/Target/ARM/ARMHazardRecognizer.cpp b/lib/Target/ARM/ARMHazardRecognizer.cpp
index 317934faec..b8d385b6e3 100644
--- a/lib/Target/ARM/ARMHazardRecognizer.cpp
+++ b/lib/Target/ARM/ARMHazardRecognizer.cpp
@@ -68,14 +68,14 @@ ARMHazardRecognizer::getHazardType(SUnit *SU) {
}
}
- return PostRAHazardRecognizer::getHazardType(SU);
+ return ScoreboardHazardRecognizer::getHazardType(SU);
}
void ARMHazardRecognizer::Reset() {
LastMI = 0;
Stalls = 0;
ITBlockSize = 0;
- PostRAHazardRecognizer::Reset();
+ ScoreboardHazardRecognizer::Reset();
}
void ARMHazardRecognizer::EmitInstruction(SUnit *SU) {
@@ -103,12 +103,16 @@ void ARMHazardRecognizer::EmitInstruction(SUnit *SU) {
Stalls = 0;
}
- PostRAHazardRecognizer::EmitInstruction(SU);
+ ScoreboardHazardRecognizer::EmitInstruction(SU);
}
void ARMHazardRecognizer::AdvanceCycle() {
if (Stalls && --Stalls == 0)
// Stalled for 4 cycles but still can't schedule any other instructions.
LastMI = 0;
- PostRAHazardRecognizer::AdvanceCycle();
+ ScoreboardHazardRecognizer::AdvanceCycle();
+}
+
+void ARMHazardRecognizer::RecedeCycle() {
+ llvm_unreachable("reverse ARM hazard checking unsupported");
}