[llvm] [NVPTX] Fix 64 bits rotations with large shift values (PR #89399)
Artem Belevich via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 22 11:37:30 PDT 2024
================
@@ -1747,8 +1747,9 @@ def ROTL64reg_sw :
".reg .b64 %lhs;\n\t"
".reg .b64 %rhs;\n\t"
".reg .u32 %amt2;\n\t"
- "shl.b64 \t%lhs, $src, $amt;\n\t"
- "sub.u32 \t%amt2, 64, $amt;\n\t"
+ "and.b32 \t%amt2, $amt, 63;\n\t"
----------------
Artem-B wrote:
SGTM.
https://github.com/llvm/llvm-project/pull/89399
More information about the llvm-commits
mailing list