aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/LLVMTargetMachine.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-01-14 19:00:06 +0000
committerChris Lattner <sabre@nondot.org>2008-01-14 19:00:06 +0000
commit459525df1e003597077197b5f802bd5d9cd7d94c (patch)
tree933455f2668c2c5dc12f858d91bd17c62f62614a /lib/CodeGen/LLVMTargetMachine.cpp
parenta6c3f80d970ea7a5c8597bca495495832a56a54b (diff)
don't create the post-ra scheduler unless it is enabled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45972 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/LLVMTargetMachine.cpp')
-rw-r--r--lib/CodeGen/LLVMTargetMachine.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/CodeGen/LLVMTargetMachine.cpp b/lib/CodeGen/LLVMTargetMachine.cpp
index b6554356ee..351554bb19 100644
--- a/lib/CodeGen/LLVMTargetMachine.cpp
+++ b/lib/CodeGen/LLVMTargetMachine.cpp
@@ -41,6 +41,12 @@ PerformLICM("machine-licm",
cl::init(false), cl::Hidden,
cl::desc("Perform loop-invariant code motion on machine code"));
+// When this works it will be on by default.
+static cl::opt<bool>
+DisablePostRAScheduler("disable-post-RA-scheduler",
+ cl::desc("Disable scheduling after register allocation"),
+ cl::init(true));
+
FileModel::Model
LLVMTargetMachine::addPassesToEmitFile(FunctionPassManager &PM,
std::ostream &Out,
@@ -103,7 +109,7 @@ LLVMTargetMachine::addPassesToEmitFile(FunctionPassManager &PM,
PM.add(createPrologEpilogCodeInserter());
// Second pass scheduler.
- if (!Fast)
+ if (!Fast && !DisablePostRAScheduler)
PM.add(createPostRAScheduler());
// Branch folding must be run after regalloc and prolog/epilog insertion.