[llvm] [AMDGPU] Ensure non-reserved CSR spilled regs are live-in (PR #146427)
Christudasan Devadasan via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 2 03:08:53 PDT 2025
================
@@ -995,6 +996,12 @@ void SIFrameLowering::emitCSRSpillStores(
}
};
+ for (const Register &Reg : make_first_range(WWMScratchRegs)) {
+ if (!MRI.isReserved(Reg)) {
+ MRI.addLiveIn(Reg);
+ MBB.addLiveIn(Reg);
+ }
----------------
cdevadas wrote:
We initially had the code that adds the wwm-regs conservatively to all Blocks LiveIn sets. We removed them earlier with one of the wwm regalloc/spill patches (I can't recollect the exact reason). I had this impression that we should at least add them to the entry block LiveIn set.
https://github.com/llvm/llvm-project/pull/146427
More information about the llvm-commits
mailing list