[llvm] [AMDGPU][CodeGen] Fold immediates in src1 operands of V_MAD/MAC/FMA/FMAC. (PR #68002)

Joe Nash via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 2 10:18:54 PDT 2023


================
@@ -3250,9 +3250,12 @@ bool SIInstrInfo::FoldImmediate(MachineInstr &UseMI, MachineInstr &DefMI,
     MachineOperand *Src2 = getNamedOperand(UseMI, AMDGPU::OpName::src2);
 
     // Multiplied part is the constant: Use v_madmk_{f16, f32}.
-    // We should only expect these to be on src0 due to canonicalization.
----------------
Sisyph wrote:

What is the referenced canonicalization and should we perhaps fix that instead?

https://github.com/llvm/llvm-project/pull/68002


More information about the llvm-commits mailing list