[PATCH] D117765: [AMDGPU][GlobalISel] Select source modifiers for VOP3Opsel

Jay Foad via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 21 02:44:17 PST 2022


foad added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUInstructionSelector.cpp:3582
+
+    if (Opcode == AMDGPU::G_FNEG) {
+      Src = MI->getOperand(1).getReg();
----------------
Since you are stripping bitcasts, don't you need the same kind of type check as in D116441, to make sure it is a 16-bit fneg?


================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUInstructionSelector.cpp:3587
+        Mods ^= SISrcMods::NEG;
+    } else if (Opcode == AMDGPU::G_FABS) {
+      Src = MI->getOperand(1).getReg();
----------------
Likewise.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D117765



More information about the llvm-commits mailing list