diff options
author | paperchalice <liujunchang97@outlook.com> | 2024-06-12 14:29:22 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-12 14:29:22 +0800 |
commit | 4b24c2dfb5c02896ec2e9855ac72eb0771d0764d (patch) | |
tree | ef6fc89bafb9a489aec935ccf56aed981c6c3f70 /llvm/lib/Target/PowerPC | |
parent | c012e487b7246239c31bd378ab074fb110631186 (diff) | |
download | llvm-4b24c2dfb5c02896ec2e9855ac72eb0771d0764d.zip llvm-4b24c2dfb5c02896ec2e9855ac72eb0771d0764d.tar.gz llvm-4b24c2dfb5c02896ec2e9855ac72eb0771d0764d.tar.bz2 |
[CodeGen][NewPM] Split `MachinePostDominators` into a concrete analysis result (#95113)
`MachinePostDominators` version of #94571.
Diffstat (limited to 'llvm/lib/Target/PowerPC')
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCBranchCoalescing.cpp | 6 | ||||
-rw-r--r-- | llvm/lib/Target/PowerPC/PPCMIPeephole.cpp | 8 |
2 files changed, 7 insertions, 7 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCBranchCoalescing.cpp b/llvm/lib/Target/PowerPC/PPCBranchCoalescing.cpp index bf63280..53b2d2a 100644 --- a/llvm/lib/Target/PowerPC/PPCBranchCoalescing.cpp +++ b/llvm/lib/Target/PowerPC/PPCBranchCoalescing.cpp @@ -166,7 +166,7 @@ public: void getAnalysisUsage(AnalysisUsage &AU) const override { AU.addRequired<MachineDominatorTreeWrapperPass>(); - AU.addRequired<MachinePostDominatorTree>(); + AU.addRequired<MachinePostDominatorTreeWrapperPass>(); MachineFunctionPass::getAnalysisUsage(AU); } @@ -196,7 +196,7 @@ FunctionPass *llvm::createPPCBranchCoalescingPass() { INITIALIZE_PASS_BEGIN(PPCBranchCoalescing, DEBUG_TYPE, "Branch Coalescing", false, false) INITIALIZE_PASS_DEPENDENCY(MachineDominatorTreeWrapperPass) -INITIALIZE_PASS_DEPENDENCY(MachinePostDominatorTree) +INITIALIZE_PASS_DEPENDENCY(MachinePostDominatorTreeWrapperPass) INITIALIZE_PASS_END(PPCBranchCoalescing, DEBUG_TYPE, "Branch Coalescing", false, false) @@ -215,7 +215,7 @@ void PPCBranchCoalescing::CoalescingCandidateInfo::clear() { void PPCBranchCoalescing::initialize(MachineFunction &MF) { MDT = &getAnalysis<MachineDominatorTreeWrapperPass>().getDomTree(); - MPDT = &getAnalysis<MachinePostDominatorTree>(); + MPDT = &getAnalysis<MachinePostDominatorTreeWrapperPass>().getPostDomTree(); TII = MF.getSubtarget().getInstrInfo(); MRI = &MF.getRegInfo(); } diff --git a/llvm/lib/Target/PowerPC/PPCMIPeephole.cpp b/llvm/lib/Target/PowerPC/PPCMIPeephole.cpp index c57b480..c5684c7 100644 --- a/llvm/lib/Target/PowerPC/PPCMIPeephole.cpp +++ b/llvm/lib/Target/PowerPC/PPCMIPeephole.cpp @@ -157,11 +157,11 @@ public: void getAnalysisUsage(AnalysisUsage &AU) const override { AU.addRequired<LiveVariables>(); AU.addRequired<MachineDominatorTreeWrapperPass>(); - AU.addRequired<MachinePostDominatorTree>(); + AU.addRequired<MachinePostDominatorTreeWrapperPass>(); AU.addRequired<MachineBlockFrequencyInfo>(); AU.addPreserved<LiveVariables>(); AU.addPreserved<MachineDominatorTreeWrapperPass>(); - AU.addPreserved<MachinePostDominatorTree>(); + AU.addPreserved<MachinePostDominatorTreeWrapperPass>(); AU.addPreserved<MachineBlockFrequencyInfo>(); MachineFunctionPass::getAnalysisUsage(AU); } @@ -201,7 +201,7 @@ void PPCMIPeephole::initialize(MachineFunction &MFParm) { MF = &MFParm; MRI = &MF->getRegInfo(); MDT = &getAnalysis<MachineDominatorTreeWrapperPass>().getDomTree(); - MPDT = &getAnalysis<MachinePostDominatorTree>(); + MPDT = &getAnalysis<MachinePostDominatorTreeWrapperPass>().getPostDomTree(); MBFI = &getAnalysis<MachineBlockFrequencyInfo>(); LV = &getAnalysis<LiveVariables>(); EntryFreq = MBFI->getEntryFreq(); @@ -2030,7 +2030,7 @@ INITIALIZE_PASS_BEGIN(PPCMIPeephole, DEBUG_TYPE, "PowerPC MI Peephole Optimization", false, false) INITIALIZE_PASS_DEPENDENCY(MachineBlockFrequencyInfo) INITIALIZE_PASS_DEPENDENCY(MachineDominatorTreeWrapperPass) -INITIALIZE_PASS_DEPENDENCY(MachinePostDominatorTree) +INITIALIZE_PASS_DEPENDENCY(MachinePostDominatorTreeWrapperPass) INITIALIZE_PASS_DEPENDENCY(LiveVariables) INITIALIZE_PASS_END(PPCMIPeephole, DEBUG_TYPE, "PowerPC MI Peephole Optimization", false, false) |