[llvm] [AMDGPU] Detect illegal 64 relocs in SIFold (PR #219141)
Jay Foad via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 27 03:51:50 PDT 2026
================
@@ -5431,6 +5442,18 @@ bool SIInstrInfo::verifyInstruction(const MachineInstr &MI,
ErrInfo = "illegal 64-bit immediate value for operand.";
return false;
}
+ // A global with a 64-bit relocation resolves to a 64-bit literal at link
----------------
jayfoad wrote:
We already know we've got a 64-bit operand so you should not need to check whether it's a 64-bit reloc. 32-bit relocs should not be valid in the first place.
Also why do you need the checks for V_MOV_B64_PSEUDO and S_MOV_B64_IMM_PSEUDO here? (And if they are needed here, why aren't they needed in the 64-bit immediate case just above?)
https://github.com/llvm/llvm-project/pull/219141
More information about the llvm-commits
mailing list