diff options
author | QingShan Zhang <qshanz@cn.ibm.com> | 2019-03-27 03:50:16 +0000 |
---|---|---|
committer | QingShan Zhang <qshanz@cn.ibm.com> | 2019-03-27 03:50:16 +0000 |
commit | 5321dcd608a1d9b1b172b33838f1cfd29e0fed10 (patch) | |
tree | db395673aef535641d46eebf839f943268cd8b61 /llvm/lib/Target/PowerPC/PPCMachineScheduler.cpp | |
parent | 06cdd7e48862b926d453447d051aff518b3205a8 (diff) | |
download | llvm-5321dcd608a1d9b1b172b33838f1cfd29e0fed10.zip llvm-5321dcd608a1d9b1b172b33838f1cfd29e0fed10.tar.gz llvm-5321dcd608a1d9b1b172b33838f1cfd29e0fed10.tar.bz2 |
[NFC][PowerPC] Custom PowerPC specific machine-scheduler
This patch lays the groundwork for extending the generic machine scheduler by providing a PPC-specific implementation.
There are no functional changes as this is an incremental patch that simply provides the necessary overrides which just
encapsulate the behavior of the generic scheduler. Subsequent patches will add specific behavior.
Differential Revision: https://reviews.llvm.org/D59284
llvm-svn: 357047
Diffstat (limited to 'llvm/lib/Target/PowerPC/PPCMachineScheduler.cpp')
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCMachineScheduler.cpp | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCMachineScheduler.cpp b/llvm/lib/Target/PowerPC/PPCMachineScheduler.cpp new file mode 100644 index 0000000..19aa53d --- /dev/null +++ b/llvm/lib/Target/PowerPC/PPCMachineScheduler.cpp @@ -0,0 +1,30 @@ +//===- PPCMachineScheduler.cpp - MI Scheduler for PowerPC -------------===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// +#include "PPCMachineScheduler.h" +using namespace llvm; + +void PPCPostRASchedStrategy::enterMBB(MachineBasicBlock *MBB) { + // Custom PPC PostRA specific behavior here. + PostGenericScheduler::enterMBB(MBB); +} + +void PPCPostRASchedStrategy::leaveMBB() { + // Custom PPC PostRA specific behavior here. + PostGenericScheduler::leaveMBB(); +} + +void PPCPostRASchedStrategy::initialize(ScheduleDAGMI *Dag) { + // Custom PPC PostRA specific initialization here. + PostGenericScheduler::initialize(Dag); +} + +SUnit *PPCPostRASchedStrategy::pickNode(bool &IsTopNode) { + // Custom PPC PostRA specific scheduling here. + return PostGenericScheduler::pickNode(IsTopNode); +} + |