[llvm] AMDGPU: Rewrite VGPR MFMAs to AGPR when directly copied to AGPR class (PR #152480)
Sirish Pande via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 7 14:24:35 PDT 2025
================
@@ -109,12 +109,17 @@ bool AMDGPURewriteAGPRCopyMFMAImpl::run(MachineFunction &MF) const {
// Find AV_* registers assigned to AGPRs.
const TargetRegisterClass *VirtRegRC = MRI.getRegClass(VReg);
- if (!TRI.isVectorSuperClass(VirtRegRC))
+ if (!TRI.hasAGPRs(VirtRegRC))
----------------
srpande wrote:
I know we don't have hasAVGPRs. But shouldn't this be something like hasAVGPR, and when looking at AssignedRC, check whether AssignedRC is a AGPRClass, which is essentially a subclass of AVGPR?
https://github.com/llvm/llvm-project/pull/152480
More information about the llvm-commits
mailing list