[PATCH] D134354: [AMDGPU][GlobalISel] Support mad/fma_mix selection

Jay Foad via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 19 02:18:53 PDT 2022


foad added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUGISel.td:156
 
+def gi_vop3_mad_mix_mods :
+    GIComplexOperandMatcher<s64, "selectVOP3PMadMixMods">,
----------------
Pierre-vh wrote:
> foad wrote:
> > Is this required? I am confused about whether you are now matching VOP3PMadMixMods in TableGen patterns, or only doing it from the C++ code in selectG_FMA.
> I'm doing it exclusively in C++.
> This is needed to tell the GlobalISelEmitter that, when it sees "VOP3PMadMixMods" it needs to use the "selectVOP3PMadMixMods" function from AMDGPUInstructionSelector.
> Without that, it wouldn't import patterns that use it.
I'm still confused. If we are now importing patterns that use VOP3PMadMixMods, why do you need to do the selection in C++ code?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D134354/new/

https://reviews.llvm.org/D134354



More information about the llvm-commits mailing list