[PATCH] D100938: neon: truncate(smin(smax(a,b),c)) --> vqmovns(a),truncate(smin(a,b)) --> vqmovnu(a)

Eye via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 21 06:25:37 PDT 2021


fantasyRqg updated this revision to Diff 339210.
fantasyRqg edited the summary of this revision.
fantasyRqg added a comment.

fix: wrong bit-width on PerformNeonTruncateMinMaxCombine::IsUnsignedSaturate


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D100938

Files:
  .gitignore
  llvm/lib/Target/ARM/ARMISelLowering.cpp


Index: llvm/lib/Target/ARM/ARMISelLowering.cpp
===================================================================
--- llvm/lib/Target/ARM/ARMISelLowering.cpp
+++ llvm/lib/Target/ARM/ARMISelLowering.cpp
@@ -16085,9 +16085,9 @@
 
     APInt SaturateC;
     if (VT == MVT::v8i8)
-      SaturateC = APInt(8, (1 << 8) - 1, true);
+      SaturateC = APInt(16, (1 << 8) - 1, true);
     else // if (VT == MVT::v4i16)
-      SaturateC = APInt(16, (1 << 16) - 1, true);
+      SaturateC = APInt(32, (1 << 16) - 1, true);
 
     APInt MinC;
     if (!ISD::isConstantSplatVector(Min->getOperand(1).getNode(), MinC) ||
Index: .gitignore
===================================================================
--- .gitignore
+++ .gitignore
@@ -26,6 +26,7 @@
 
 # Nested build directory
 /build*
+**/cmake-build*
 
 #==============================================================================#
 # Explicit files to ignore (only matches one).


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D100938.339210.patch
Type: text/x-patch
Size: 928 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210421/61e87bf2/attachment.bin>


More information about the llvm-commits mailing list