[llvm] [ReachingDefAnalysis] Extend the analysis to stack objects. (PR #118097)

Mikhail Gudim via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 10 09:47:18 PST 2025


================
@@ -422,7 +507,7 @@ void ReachingDefAnalysis::getLiveOuts(MachineBasicBlock *MBB, MCRegister Reg,
   VisitedBBs.insert(MBB);
   LiveRegUnits LiveRegs(*TRI);
   LiveRegs.addLiveOuts(*MBB);
-  if (LiveRegs.available(Reg))
+  if (Register::isPhysicalRegister(Reg) && LiveRegs.available(Reg))
----------------
mgudim wrote:

I think so too. I am trying to come up with a test case which shows we HAVE TO extend LiveRegs to stack slots too.

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


More information about the llvm-commits mailing list