summaryrefslogtreecommitdiff
path: root/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2009-12-15 01:54:51 +0000
committerBill Wendling <isanbard@gmail.com>2009-12-15 01:54:51 +0000
commit614407a9d21d10ee4f6c45295852c72ad86cb029 (patch)
tree7b838aaf9312251191e651bf760d0aaf801fd25f /lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
parent3466f13f38b2f3e652cca82bd5da8527e72e195d (diff)
downloadllvm-614407a9d21d10ee4f6c45295852c72ad86cb029.tar.gz
llvm-614407a9d21d10ee4f6c45295852c72ad86cb029.tar.bz2
llvm-614407a9d21d10ee4f6c45295852c72ad86cb029.tar.xz
Initial work on disabling the scheduler. This is a work in progress, and this
stuff isn't used just yet. We want to model the GCC `-fno-schedule-insns' and `-fno-schedule-insns2' flags. The hypothesis is that the people who use these flags know what they are doing, and have hand-optimized the C code to reduce latencies and other conflicts. The idea behind our scheme to turn off scheduling is to create a map "on the side" during DAG generation. It will order the nodes by how they appeared in the code. This map is then used during scheduling to get the ordering. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@91392 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp')
-rw-r--r--lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp b/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
index d53de347a5..b2ee8bb179 100644
--- a/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
+++ b/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp
@@ -20,10 +20,16 @@
#include "llvm/Target/TargetInstrInfo.h"
#include "llvm/Target/TargetRegisterInfo.h"
#include "llvm/Target/TargetSubtarget.h"
+#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/raw_ostream.h"
using namespace llvm;
+cl::opt<bool>
+DisableInstScheduling("disable-inst-scheduling",
+ cl::init(false),
+ cl::desc("Disable instruction scheduling"));
+
ScheduleDAGSDNodes::ScheduleDAGSDNodes(MachineFunction &mf)
: ScheduleDAG(mf) {
}