aboutsummaryrefslogtreecommitdiffstats
path: root/lib/CodeGen/InstrSched/InstrScheduling.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/CodeGen/InstrSched/InstrScheduling.cpp')
-rw-r--r--lib/CodeGen/InstrSched/InstrScheduling.cpp19
1 files changed, 7 insertions, 12 deletions
diff --git a/lib/CodeGen/InstrSched/InstrScheduling.cpp b/lib/CodeGen/InstrSched/InstrScheduling.cpp
index f10bf3c412..adc8903541 100644
--- a/lib/CodeGen/InstrSched/InstrScheduling.cpp
+++ b/lib/CodeGen/InstrSched/InstrScheduling.cpp
@@ -1480,26 +1480,23 @@ instrIsFeasible(const SchedulingManager& S,
//---------------------------------------------------------------------------
namespace {
- class InstructionSchedulingWithSSA : public MethodPass {
+ class InstructionSchedulingWithSSA : public FunctionPass {
const TargetMachine ⌖
public:
inline InstructionSchedulingWithSSA(const TargetMachine &T) : target(T) {}
- // getAnalysisUsageInfo - We use LiveVarInfo...
- virtual void getAnalysisUsageInfo(Pass::AnalysisSet &Requires,
- Pass::AnalysisSet &Destroyed,
- Pass::AnalysisSet &Provided) {
- Requires.push_back(MethodLiveVarInfo::ID);
- Destroyed.push_back(MethodLiveVarInfo::ID);
+ // getAnalysisUsage - We use LiveVarInfo...
+ virtual void getAnalysisUsage(AnalysisUsage &AU) const {
+ AU.addRequired(MethodLiveVarInfo::ID);
}
- bool runOnMethod(Function *F);
+ bool runOnFunction(Function *F);
};
} // end anonymous namespace
bool
-InstructionSchedulingWithSSA::runOnMethod(Function *M)
+InstructionSchedulingWithSSA::runOnFunction(Function *M)
{
if (SchedDebugLevel == Sched_Disable)
return false;
@@ -1544,8 +1541,6 @@ InstructionSchedulingWithSSA::runOnMethod(Function *M)
}
-MethodPass*
-createInstructionSchedulingWithSSAPass(const TargetMachine &tgt)
-{
+Pass *createInstructionSchedulingWithSSAPass(const TargetMachine &tgt) {
return new InstructionSchedulingWithSSA(tgt);
}