[PATCH] D132516: [NVPTX] SHL.64 $r, 31 cannot be converted to a mulwide.s32

Artem Belevich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 23 17:05:35 PDT 2022


tra added a comment.

Good catch.



================
Comment at: llvm/lib/Target/NVPTX/NVPTXInstrInfo.td:734
 
 def Int5Const : PatLeaf<(imm), [{
+  // Check if 0 <= v < 31; only then will the result of (x << v) be an int32.
----------------
Now that we're not just checking whether the constant fits in 5 bits, the constraint needs a new name.
`IntConst_0_30` ?


================
Comment at: llvm/lib/Target/NVPTX/NVPTXInstrInfo.td:740
 
 def Int4Const : PatLeaf<(imm), [{
+  // Check if 0 <= v < 15; only then will the result of (x << v) be an int16.
----------------
ditto.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D132516



More information about the llvm-commits mailing list