[llvm] [CodeGen] Use shared RegClassInfo in basic, greedy and fast allocators (PR #226523)

Nikhil Kotikalapudi via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 25 09:57:04 PDT 2026


================
@@ -1933,10 +1941,11 @@ bool RegAllocFastImpl::runOnMachineFunction(MachineFunction &MF) {
 }
 
 PreservedAnalyses RegAllocFastPass::run(MachineFunction &MF,
-                                        MachineFunctionAnalysisManager &) {
+                                        MachineFunctionAnalysisManager &MFAM) {
   MFPropsModifier _(*this, MF);
   RegAllocFastImpl Impl(Opts.Filter, Opts.ClearVRegs);
-  bool Changed = Impl.runOnMachineFunction(MF);
+  bool Changed = Impl.runOnMachineFunction(
+      MF, MFAM.getResult<MachineRegisterClassAnalysis>(MF));
----------------
nkotikal wrote:

I forget what the new pm uses but this does the same as legacy pm's getAnalysis....getRCI() right?

https://github.com/llvm/llvm-project/pull/226523


More information about the llvm-commits mailing list