[llvm] [AMDGPU] More accurately account for AVGPR pressure (PR #150711)
Jeffrey Byrnes via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 4 14:57:21 PDT 2025
================
@@ -99,20 +99,22 @@ void GCNRegPressure::inc(unsigned Reg,
bool GCNRegPressure::less(const MachineFunction &MF, const GCNRegPressure &O,
unsigned MaxOccupancy) const {
const GCNSubtarget &ST = MF.getSubtarget<GCNSubtarget>();
+ unsigned ArchVGPRThreshold = ST.getMaxNumVectorRegs(MF.getFunction()).first;
----------------
jrbyrnes wrote:
I think it is better to bury the details in GCNRegPressure to reduce burden on the caller like you say. I can't imagine a case where we would be working with GCNRegPressure and the MF isn't available..
https://github.com/llvm/llvm-project/pull/150711
More information about the llvm-commits
mailing list