[PATCH] D124192: [AMDGPU] Callee must always spill writelane VGPRs
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 29 10:47:49 PDT 2022
arsenm added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/SIFrameLowering.cpp:782-783
+ for (const auto &Reg : FuncInfo->getLaneVGPRs()) {
+ auto VGPR = Reg.first;
+ auto FI = Reg.second;
+ if (!FI)
----------------
No auto
================
Comment at: llvm/lib/Target/AMDGPU/SIFrameLowering.cpp:1263
+ if (MI.getOpcode() == AMDGPU::V_WRITELANE_B32)
+ MFI->addToLaneVGPRs(MF, MI.getOperand(0).getReg());
+ }
----------------
I don't think this is the right place to determine these registers. It's adding an extra loop over the function, and adding statefulness to determineCalleeSaves. Theoretically we should be able to call it multiple times
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D124192/new/
https://reviews.llvm.org/D124192
More information about the llvm-commits
mailing list