Changes from review:

- Move DisableScheduling flag into TargetOption.h
- Move SDNodeOrdering into its own header file. Give it a minimal interface that
  doesn't conflate construction with storage.
- Move assigning the ordering into the SelectionDAGBuilder.

This isn't used yet, so there should be no functional changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@91727 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/TargetMachine.cpp b/lib/Target/TargetMachine.cpp
index fec59b5..46bc9a3 100644
--- a/lib/Target/TargetMachine.cpp
+++ b/lib/Target/TargetMachine.cpp
@@ -46,6 +46,7 @@
   bool DisableJumpTables;
   bool StrongPHIElim;
   bool AsmVerbosityDefault(false);
+  bool DisableScheduling;
 }
 
 static cl::opt<bool, true>
@@ -197,6 +198,11 @@
   cl::desc("Use strong PHI elimination."),
   cl::location(StrongPHIElim),
   cl::init(false));
+static cl::opt<bool, true>
+DisableInstScheduling("disable-scheduling",
+  cl::desc("Disable instruction scheduling"),
+  cl::location(DisableScheduling),
+  cl::init(false));
 
 //---------------------------------------------------------------------------
 // TargetMachine Class