[llvm] [VectorCombine] Merge duplicate shuffle instruction nodes (PR #182768)

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 22 06:10:16 PDT 2026


================
@@ -3480,23 +3489,28 @@ bool VectorCombine::foldShuffleOfIntrinsics(Instruction &I) {
   SmallVector<Type *> NewArgsTy;
   InstructionCost NewCost = 0;
   SmallDenseSet<std::pair<Value *, Value *>> SeenOperandPairs;
-  for (unsigned I = 0, E = II0->arg_size(); I != E; ++I) {
-    if (isVectorIntrinsicWithScalarOpAtArg(IID, I, &TTI)) {
-      NewArgsTy.push_back(II0->getArgOperand(I)->getType());
+  for (unsigned Idx = 0, E = II0->arg_size(); Idx != E; ++Idx) {
----------------
RKSimon wrote:

These Wshadow fixes should be in a separate PR

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


More information about the llvm-commits mailing list