[llvm] [ValueTracking][X86] Compute KnownBits for phadd/phsub (PR #92429)

via llvm-commits llvm-commits at lists.llvm.org
Sat Jun 8 10:59:29 PDT 2024


================
@@ -541,6 +541,33 @@ void llvm::processShuffleMasks(
   }
 }
 
+void llvm::getHorizDemandedEltsForFirstOperand(unsigned VectorBitWidth,
+                                               const APInt &DemandedElts,
+                                               APInt &DemandedLHS,
+                                               APInt &DemandedRHS) {
+  int NumLanes = std::max<int>(1, VectorBitWidth / 128);
----------------
goldsteinn wrote:

Otherwise add a few cases w/ width < 128 in your unit tests.

https://github.com/llvm/llvm-project/pull/92429


More information about the llvm-commits mailing list