summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target
diff options
context:
space:
mode:
authorAndrew Trick <atrick@apple.com>2013-01-25 06:33:57 +0000
committerAndrew Trick <atrick@apple.com>2013-01-25 06:33:57 +0000
commite2c3f5c982806603cdd1199d1061aeee7e14f9ed (patch)
tree33e4f7435fbd1ea0fe7af9d22eef8368bb7e3085 /llvm/lib/Target
parentf443f11589769d62e42b7e978af8d3ea4b5d963c (diff)
downloadbcm5719-llvm-e2c3f5c982806603cdd1199d1061aeee7e14f9ed.tar.gz
bcm5719-llvm-e2c3f5c982806603cdd1199d1061aeee7e14f9ed.zip
MIsched: Improve the interface to SchedDFS analysis (subtrees).
Allow the strategy to select SchedDFS. Allow the results of SchedDFS to affect initialization of the scheduler state. llvm-svn: 173425
Diffstat (limited to 'llvm/lib/Target')
-rw-r--r--llvm/lib/Target/Hexagon/HexagonMachineScheduler.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/llvm/lib/Target/Hexagon/HexagonMachineScheduler.cpp b/llvm/lib/Target/Hexagon/HexagonMachineScheduler.cpp
index aef68307526..36dfaa4233f 100644
--- a/llvm/lib/Target/Hexagon/HexagonMachineScheduler.cpp
+++ b/llvm/lib/Target/Hexagon/HexagonMachineScheduler.cpp
@@ -152,6 +152,12 @@ void VLIWMachineScheduler::schedule() {
// Postprocess the DAG to add platform specific artificial dependencies.
postprocessDAG();
+ SmallVector<SUnit*, 8> TopRoots, BotRoots;
+ findRootsAndBiasEdges(TopRoots, BotRoots);
+
+ // Initialize the strategy before modifying the DAG.
+ SchedImpl->initialize(this);
+
// To view Height/Depth correctly, they should be accessed at least once.
DEBUG(unsigned maxH = 0;
for (unsigned su = 0, e = SUnits.size(); su != e; ++su)
@@ -166,7 +172,7 @@ void VLIWMachineScheduler::schedule() {
DEBUG(for (unsigned su = 0, e = SUnits.size(); su != e; ++su)
SUnits[su].dumpAll(this));
- initQueues();
+ initQueues(TopRoots, BotRoots);
bool IsTopNode = false;
while (SUnit *SU = SchedImpl->pickNode(IsTopNode)) {
OpenPOWER on IntegriCloud