[llvm] [llvm][CodeGen] Add a new software pipeliner 'Window Scheduler' (PR #84443)
Hua Tian via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 12 04:31:43 PDT 2024
================
@@ -484,9 +499,35 @@ void MachinePipeliner::getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequired<MachineDominatorTree>();
AU.addRequired<LiveIntervals>();
AU.addRequired<MachineOptimizationRemarkEmitterPass>();
+ AU.addRequired<TargetPassConfig>();
MachineFunctionPass::getAnalysisUsage(AU);
}
+bool MachinePipeliner::runWindowScheduler(MachineLoop &L) {
+ MachineSchedContext Context;
+ Context.MF = MF;
+ Context.MLI = MLI;
+ Context.MDT = MDT;
+ Context.PassConfig = &getAnalysis<TargetPassConfig>();
+ Context.AA = &getAnalysis<AAResultsWrapperPass>().getAAResults();
+ Context.LIS = &getAnalysis<LiveIntervals>();
+ Context.RegClassInfo->runOnMachineFunction(*MF);
+ WindowScheduler WS(&Context, L);
+ return WS.run();
+}
+
+bool MachinePipeliner::useSwingModuloScheduler(bool Changed) {
----------------
huaatian wrote:
Fixed
https://github.com/llvm/llvm-project/pull/84443
More information about the llvm-commits
mailing list