mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-03 02:43:51 +00:00
MachineScheduler: Add a command line option to disable post scheduler.
llvm-svn: 258364
This commit is contained in:
parent
176047fcfd
commit
0c74edaf2c
@ -219,6 +219,11 @@ static cl::opt<bool> EnableMachineSched(
|
||||
cl::desc("Enable the machine instruction scheduling pass."), cl::init(true),
|
||||
cl::Hidden);
|
||||
|
||||
static cl::opt<bool> EnablePostRAMachineSched(
|
||||
"enable-post-misched",
|
||||
cl::desc("Enable the post-ra machine instruction scheduling pass."),
|
||||
cl::init(true), cl::Hidden);
|
||||
|
||||
/// Forward declare the standard machine scheduler. This will be used as the
|
||||
/// default scheduler if the target does not set a default.
|
||||
static ScheduleDAGInstrs *createGenericSchedLive(MachineSchedContext *C);
|
||||
@ -355,7 +360,10 @@ bool PostMachineScheduler::runOnMachineFunction(MachineFunction &mf) {
|
||||
if (skipOptnoneFunction(*mf.getFunction()))
|
||||
return false;
|
||||
|
||||
if (!mf.getSubtarget().enablePostRAScheduler()) {
|
||||
if (EnablePostRAMachineSched.getNumOccurrences()) {
|
||||
if (!EnablePostRAMachineSched)
|
||||
return false;
|
||||
} else if (!mf.getSubtarget().enablePostRAScheduler()) {
|
||||
DEBUG(dbgs() << "Subtarget disables post-MI-sched.\n");
|
||||
return false;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user