[llvm] [X86] Correct folded insert costs for partial vector loads (PR #220174)

via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 1 00:14:40 PDT 2026


llvmorg-github-actions[bot] wrote:


<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-llvm-transforms

@llvm/pr-subscribers-llvm-analysis

Author: Milin Bhade (mbhade-amd)

<details>
<summary>Changes</summary>

The SLP vectorizer can form non-power-of-two trees, including width-3 trees, but relies on target costs to determine profitability:
https://github.com/llvm/llvm-project/pull/194189
X86 getMemoryOpCost overestimated non-power-of-two vector loads by counting a folded PINSR*(mem) chunk as both a memory operation and a separate lane insertion.
Recognize non-0th folded load-insert chunks and charge each once. Leading sub-dword loads, stores, and 8-byte chunks remain unchanged.

cc @<!-- -->ganeshgit 

---

Patch is 212.90 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/220174.diff


11 Files Affected:

- (modified) llvm/lib/Target/X86/X86TargetTransformInfo.cpp (+17-4) 
- (modified) llvm/test/Analysis/CostModel/X86/load_store.ll (+653-653) 
- (added) llvm/test/Analysis/CostModel/X86/nonpow2-load-fold.ll (+68) 
- (modified) llvm/test/Transforms/LoopVectorize/X86/CostModel/interleaved-load-i16-stride-3.ll (+2-2) 
- (modified) llvm/test/Transforms/LoopVectorize/X86/CostModel/interleaved-load-i16-stride-5.ll (+1-1) 
- (modified) llvm/test/Transforms/LoopVectorize/X86/CostModel/interleaved-load-i16-stride-7.ll (+1-1) 
- (modified) llvm/test/Transforms/LoopVectorize/X86/CostModel/interleaved-load-i8-stride-3.ll (+4-4) 
- (modified) llvm/test/Transforms/LoopVectorize/X86/CostModel/interleaved-load-i8-stride-5.ll (+2-2) 
- (modified) llvm/test/Transforms/LoopVectorize/X86/CostModel/interleaved-load-i8-stride-6.ll (+2-2) 
- (modified) llvm/test/Transforms/LoopVectorize/X86/CostModel/interleaved-load-i8-stride-7.ll (+2-2) 
- (added) llvm/test/Transforms/SLPVectorizer/X86/nonpow2-shared-weight-reduction.ll (+150) 


``````````diff
diff --git a/llvm/lib/Target/X86/X86TargetTransformInfo.cpp b/llvm/lib/Target/X86/X86TargetTransformInfo.cpp
index e3d838a7f4fde..dc36788f79e44 100644
--- a/llvm/lib/Target/X86/X86TargetTransformInfo.cpp
+++ b/llvm/lib/Target/X86/X86TargetTransformInfo.cpp
@@ -5548,9 +5548,24 @@ InstructionCost X86TTIImpl::getMemoryOpCost(unsigned Opcode, Type *Src,
       // Sandybridge.
       // Sub-32-bit loads/stores will be slower either with PINSR*/PEXTR* or
       // will be scalarized.
+      //
+      // For a vector load, each non-0th 1/2/4-byte in-lane remainder chunk is
+      // materialized by a *single* folded PINSR*(mem) that both loads and
+      // inserts the lane (1B->PINSRB, 2B->PINSRW, 4B->PINSRD; the byte and
+      // dword folds need SSE4.1, the word fold only SSE2).
+      // When that fold is available the chunk is one instruction, so it must be
+      // priced once here (as a plain load) and the separate lane-insert charge
+      // below must be skipped - otherwise the folded insert is double-counted.
+      // Stores (the symmetric PEXTR*(mem) fold) are left unchanged here.
+      bool Is0thSubVec = (NumEltDone() % LT.second.getVectorNumElements()) == 0;
+      bool FoldedInLaneInsert =
+          IsLoad && !Is0thSubVec &&
+          ((CurrOpSizeBytes == 1 && ST->hasSSE41()) ||
+           (CurrOpSizeBytes == 2 && ST->hasSSE2()) ||
+           (CurrOpSizeBytes == 4 && ST->hasSSE41()));
       if (CurrOpSizeBytes == 32 && ST->isUnalignedMem32Slow())
         Cost += 2;
-      else if (CurrOpSizeBytes < 4)
+      else if (CurrOpSizeBytes < 4 && !FoldedInLaneInsert)
         Cost += 2;
       else
         Cost += 1;
@@ -5560,8 +5575,6 @@ InstructionCost X86TTIImpl::getMemoryOpCost(unsigned Opcode, Type *Src,
       if (IsLoad && OpInfo.isUniform())
         return Cost;
 
-      bool Is0thSubVec = (NumEltDone() % LT.second.getVectorNumElements()) == 0;
-
       // If we have fully processed the previous reg, we need to replenish it.
       if (SubVecEltsLeft == 0) {
         SubVecEltsLeft += CurrVecTy->getNumElements();
@@ -5577,7 +5590,7 @@ InstructionCost X86TTIImpl::getMemoryOpCost(unsigned Opcode, Type *Src,
       // for smaller widths (32/16/8) we have to insert/extract them separately.
       // Again, it's free for the 0'th subreg (if op is 32/64 bit wide,
       // but let's pretend that it is also true for 16/8 bit wide ops...)
-      if (CurrOpSizeBytes <= 32 / 8 && !Is0thSubVec) {
+      if (CurrOpSizeBytes <= 32 / 8 && !Is0thSubVec && !FoldedInLaneInsert) {
         int NumEltDoneInCurrXMM = NumEltDone() % NumEltPerXMM;
         assert(NumEltDoneInCurrXMM % CurrNumEltPerOp == 0 && "");
         int CoalescedVecEltIdx = NumEltDoneInCurrXMM / CurrNumEltPerOp;
diff --git a/llvm/test/Analysis/CostModel/X86/load_store.ll b/llvm/test/Analysis/CostModel/X86/load_store.ll
index ef36bd7070724..0db96a06c578f 100644
--- a/llvm/test/Analysis/CostModel/X86/load_store.ll
+++ b/llvm/test/Analysis/CostModel/X86/load_store.ll
@@ -4222,120 +4222,120 @@ define i32 @loads_partial_align4(i32 %arg) {
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %10 = load <7 x double>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %11 = load <1 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %12 = load <2 x i32>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %13 = load <3 x i32>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %13 = load <3 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %14 = load <5 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %15 = load <6 x i32>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %16 = load <7 x i32>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %16 = load <7 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %17 = load <9 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %18 = load <10 x i32>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %19 = load <11 x i32>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %19 = load <11 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %20 = load <12 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %21 = load <13 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %22 = load <14 x i32>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %23 = load <15 x i32>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %23 = load <15 x i32>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %24 = load <1 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %25 = load <2 x float>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %26 = load <3 x float>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %26 = load <3 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %27 = load <5 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %28 = load <6 x float>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %29 = load <7 x float>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %29 = load <7 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %30 = load <9 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %31 = load <10 x float>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %32 = load <11 x float>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %32 = load <11 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %33 = load <12 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %34 = load <13 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %35 = load <14 x float>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %36 = load <15 x float>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %36 = load <15 x float>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %37 = load <1 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %38 = load <2 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %39 = load <3 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %39 = load <3 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %40 = load <4 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %41 = load <5 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %42 = load <6 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %43 = load <7 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %41 = load <5 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %42 = load <6 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %43 = load <7 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %44 = load <9 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %45 = load <10 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %46 = load <11 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %46 = load <11 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %47 = load <12 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %48 = load <13 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %49 = load <14 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %50 = load <15 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %48 = load <13 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %49 = load <14 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %50 = load <15 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %51 = load <17 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %52 = load <18 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %53 = load <19 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %53 = load <19 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %54 = load <20 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %55 = load <21 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %56 = load <22 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 7 for instruction: %57 = load <23 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %55 = load <21 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %56 = load <22 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %57 = load <23 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %58 = load <24 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %59 = load <25 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %60 = load <26 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %61 = load <27 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %61 = load <27 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %62 = load <28 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %63 = load <29 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %64 = load <30 x i16>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %65 = load <31 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %63 = load <29 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %64 = load <30 x i16>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %65 = load <31 x i16>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %66 = load <1 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %67 = load <2 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %68 = load <3 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %69 = load <4 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %70 = load <5 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %71 = load <6 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %72 = load <7 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %70 = load <5 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %71 = load <6 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %72 = load <7 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %73 = load <8 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %74 = load <9 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %75 = load <10 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %76 = load <11 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %77 = load <12 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %78 = load <13 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %79 = load <14 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %80 = load <15 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %74 = load <9 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %75 = load <10 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %76 = load <11 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %77 = load <12 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %78 = load <13 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %79 = load <14 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %80 = load <15 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %81 = load <17 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %82 = load <18 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %83 = load <19 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %84 = load <20 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %85 = load <21 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %86 = load <22 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %87 = load <23 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %85 = load <21 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %86 = load <22 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %87 = load <23 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %88 = load <24 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %89 = load <25 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %90 = load <26 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %91 = load <27 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %92 = load <28 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %93 = load <29 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %94 = load <30 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 6 for instruction: %95 = load <31 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %89 = load <25 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %90 = load <26 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %91 = load <27 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %92 = load <28 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %93 = load <29 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %94 = load <30 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %95 = load <31 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %96 = load <33 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %97 = load <34 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %98 = load <35 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %99 = load <36 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %100 = load <37 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %101 = load <38 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %102 = load <39 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %100 = load <37 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %101 = load <38 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %102 = load <39 x i8>, ptr undef, align 4
 ; SSE41-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: %103 = load <40 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %104 = load <41 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %105 = load <42 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %106 = load <43 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 5 for instruction: %107 = load <44 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 7 for instruction: %108 = load <45 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 7 for instruction: %109 = load <46 x i8>, ptr undef, align 4
-; SSE41-NEXT:  Cost Model: Found an estimated cost of 7 for instruction: %110 = load <47 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %104 = load <41 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %105 = load <42 x i8>, ptr undef, align 4
+; SSE41-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %106 =...
[truncated]

``````````

</details>


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


More information about the llvm-commits mailing list