[PATCH] D42078: AMDGPU: Fold inline offset for loads properly in moveToVALU on GFX9

Nicolai Hähnle via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 24 09:16:46 PST 2018


nhaehnle added inline comments.


================
Comment at: lib/Target/AMDGPU/SIInstrInfo.cpp:3768-3770
+      if (Add &&
+          (Add->getOpcode() == AMDGPU::V_ADD_I32_e32 ||
+           Add->getOpcode() == AMDGPU::V_ADD_U32_e64)) {
----------------
Why not V_ADD_I32_e64 and V_ADD_U32_e32 as well? Those should work the same.

You can also remove the corresponding FIXME in the comment.

Also, to support e64/VOP3, the code must check for clamp and imod (abs/neg) bits and bail out when they're set. Clamp is genuinely supported for integer ops since gfx9, and while imods will not do anything useful, they *will* affect the instruction (they just affect the MSB as if the instruction were a floating point operation).


Repository:
  rL LLVM

https://reviews.llvm.org/D42078





More information about the llvm-commits mailing list