In a kernel which does not have calls or AGPR usage we can allocate
the whole vector register budget for VGPRs and have no AGPRs as
long as VGPRs stay addressable (i.e. below 256).
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h | ||
---|---|---|
953 | Why not just make this a manipulator (delete the trailing const) and get rid of mutable? It's just a stylistic issue so feel free to ignore. |
llvm/lib/Target/AMDGPU/SIMachineFunctionInfo.h | ||
---|---|---|
953 | Because getReservedRegs takes const MF. So it is either mutable or I will have to use const_cast somewhere. I prefer mutable in this case as it is just lazily computed and cached rather than actually changing the MFI. The effects of this mutation are unobservable outside of the accessor. |
Why not just make this a manipulator (delete the trailing const) and get rid of mutable? It's just a stylistic issue so feel free to ignore.