Skip to content

Commit 8b64212

Browse files
committed
[RISCV][TTI] Add costing for masked slide lowering
This change adds the TTI costing corresponding to the recently added isMaskedSlidePair lowering for vector shuffles. However, since the existing costing code hadn't covered either slideup, slidedown, or the (now removed) isElementRotate, the impact is larger in scope than just that new lowering.
1 parent 529b3d1 commit 8b64212

File tree

11 files changed

+297
-702
lines changed

11 files changed

+297
-702
lines changed

llvm/include/llvm/Analysis/VectorUtils.h

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,15 @@ bool getShuffleDemandedElts(int SrcWidth, ArrayRef<int> Mask,
203203
const APInt &DemandedElts, APInt &DemandedLHS,
204204
APInt &DemandedRHS, bool AllowUndefElts = false);
205205

206+
/// Does this shuffle mask represent either one slide shuffle or a pair of
207+
/// two slide shuffles, combined with a select on some constant vector mask?
208+
/// A slide is a shuffle masks which shifts some set of elements up or down
209+
/// the vector, with all other elements being undefined. An identity shuffle
210+
/// will be matched a slide by 0. The output parameter provides the source
211+
/// (-1 means no source), and slide direction for each slide.
212+
bool isMaskedSlidePair(ArrayRef<int> Mask, int NumElts,
213+
std::pair<int, int> SrcInfo[2]);
214+
206215
/// Replace each shuffle mask index with the scaled sequential indices for an
207216
/// equivalent mask of narrowed elements. Mask elements that are less than 0
208217
/// (sentinel values) are repeated in the output mask.

llvm/lib/Analysis/VectorUtils.cpp

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -413,6 +413,36 @@ bool llvm::getShuffleDemandedElts(int SrcWidth, ArrayRef<int> Mask,
413413
return true;
414414
}
415415

416+
bool llvm::isMaskedSlidePair(ArrayRef<int> Mask, int NumElts,
417+
std::pair<int, int> SrcInfo[2]) {
418+
int SignalValue = NumElts * 2;
419+
SrcInfo[0] = {-1, SignalValue};
420+
SrcInfo[1] = {-1, SignalValue};
421+
for (unsigned i = 0; i != Mask.size(); ++i) {
422+
int M = Mask[i];
423+
if (M < 0)
424+
continue;
425+
int Src = M >= (int)NumElts;
426+
int Diff = (int)i - (M % NumElts);
427+
bool Match = false;
428+
for (int j = 0; j < 2; j++) {
429+
if (SrcInfo[j].first == -1) {
430+
assert(SrcInfo[j].second == SignalValue);
431+
SrcInfo[j].first = Src;
432+
SrcInfo[j].second = Diff;
433+
}
434+
if (SrcInfo[j].first == Src && SrcInfo[j].second == Diff) {
435+
Match = true;
436+
break;
437+
}
438+
}
439+
if (!Match)
440+
return false;
441+
}
442+
assert(SrcInfo[0].first != -1 && "Must find one slide");
443+
return true;
444+
}
445+
416446
void llvm::narrowShuffleMaskElts(int Scale, ArrayRef<int> Mask,
417447
SmallVectorImpl<int> &ScaledMask) {
418448
assert(Scale > 0 && "Unexpected scaling factor");

llvm/lib/Target/RISCV/RISCVISelLowering.cpp

Lines changed: 4 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -4563,31 +4563,8 @@ static bool isInterleaveShuffle(ArrayRef<int> Mask, MVT VT, int &EvenSrc,
45634563
/// Is this mask representing a masked combination of two slides?
45644564
static bool isMaskedSlidePair(ArrayRef<int> Mask,
45654565
std::pair<int, int> SrcInfo[2]) {
4566-
int NumElts = Mask.size();
4567-
int SignalValue = NumElts * 2;
4568-
SrcInfo[0] = {-1, SignalValue};
4569-
SrcInfo[1] = {-1, SignalValue};
4570-
for (unsigned i = 0; i != Mask.size(); ++i) {
4571-
int M = Mask[i];
4572-
if (M < 0)
4573-
continue;
4574-
int Src = M >= (int)NumElts;
4575-
int Diff = (int)i - (M % NumElts);
4576-
bool Match = false;
4577-
for (int j = 0; j < 2; j++) {
4578-
if (SrcInfo[j].first == -1) {
4579-
assert(SrcInfo[j].second == SignalValue);
4580-
SrcInfo[j].first = Src;
4581-
SrcInfo[j].second = Diff;
4582-
}
4583-
if (SrcInfo[j].first == Src && SrcInfo[j].second == Diff) {
4584-
Match = true;
4585-
break;
4586-
}
4587-
}
4588-
if (!Match)
4589-
return false;
4590-
}
4566+
if (!llvm::isMaskedSlidePair(Mask, Mask.size(), SrcInfo))
4567+
return false;
45914568

45924569
// Avoid matching vselect idioms
45934570
if (SrcInfo[0].second == 0 && SrcInfo[1].second == 0)
@@ -5607,7 +5584,7 @@ static SDValue lowerVECTOR_SHUFFLE(SDValue Op, SelectionDAG &DAG,
56075584
std::pair<int, int> SrcInfo[2];
56085585
unsigned RotateAmt;
56095586
MVT RotateVT;
5610-
if (isMaskedSlidePair(Mask, SrcInfo) &&
5587+
if (::isMaskedSlidePair(Mask, SrcInfo) &&
56115588
(isElementRotate(SrcInfo, NumElts) ||
56125589
!isLegalBitRotate(Mask, VT, Subtarget, RotateVT, RotateAmt))) {
56135590
SDValue Sources[2];
@@ -5967,7 +5944,7 @@ bool RISCVTargetLowering::isShuffleMaskLegal(ArrayRef<int> M, EVT VT) const {
59675944
std::pair<int, int> SrcInfo[2];
59685945
int Dummy1, Dummy2;
59695946
return ShuffleVectorInst::isReverseMask(M, NumElts) ||
5970-
(isMaskedSlidePair(M, SrcInfo) && isElementRotate(SrcInfo, NumElts)) ||
5947+
(::isMaskedSlidePair(M, SrcInfo) && isElementRotate(SrcInfo, NumElts)) ||
59715948
isInterleaveShuffle(M, SVT, Dummy1, Dummy2, Subtarget);
59725949
}
59735950

llvm/lib/Target/RISCV/RISCVTargetTransformInfo.cpp

Lines changed: 66 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -474,6 +474,60 @@ costShuffleViaVRegSplitting(RISCVTTIImpl &TTI, MVT LegalVT,
474474
return InstructionCost::getInvalid();
475475
}
476476

477+
InstructionCost RISCVTTIImpl::getSlideCost(FixedVectorType *Tp, ArrayRef<int> Mask,
478+
TTI::TargetCostKind CostKind) {
479+
// Avoid missing masks
480+
if (Mask.size() <= 2)
481+
return InstructionCost::getInvalid();
482+
483+
int NumElts = Tp->getNumElements();
484+
std::pair<InstructionCost, MVT> LT = getTypeLegalizationCost(Tp);
485+
// Avoid scalarization cases
486+
if (!LT.second.isFixedLengthVector())
487+
return InstructionCost::getInvalid();
488+
489+
// Requires moving elements between parts, which requires additional
490+
// unmodeled instructions.
491+
if (LT.first != 1)
492+
return InstructionCost::getInvalid();
493+
494+
auto getSlideOpcode = [&](int SlideAmt) {
495+
assert(SlideAmt != 0);
496+
if (SlideAmt < 0)
497+
return SlideAmt > -32 ? RISCV::VSLIDEDOWN_VI : RISCV::VSLIDEDOWN_VX;
498+
return SlideAmt < 32 ? RISCV::VSLIDEUP_VI : RISCV::VSLIDEUP_VX;
499+
};
500+
501+
std::pair<int, int> SrcInfo[2];
502+
if (!isMaskedSlidePair(Mask, NumElts, SrcInfo))
503+
return InstructionCost::getInvalid();
504+
505+
if (SrcInfo[1].second == 0)
506+
std::swap(SrcInfo[0], SrcInfo[1]);
507+
508+
InstructionCost FirstSlideCost = 0;
509+
if (SrcInfo[0].second != 0) {
510+
unsigned Opcode = getSlideOpcode(SrcInfo[0].second);
511+
FirstSlideCost = getRISCVInstructionCost(Opcode, LT.second, CostKind);
512+
}
513+
514+
if (SrcInfo[1].first == -1)
515+
return FirstSlideCost;
516+
517+
InstructionCost SecondSlideCost = 0;
518+
if (SrcInfo[1].second != 0) {
519+
unsigned Opcode = getSlideOpcode(SrcInfo[1].second);
520+
SecondSlideCost = getRISCVInstructionCost(Opcode, LT.second, CostKind);
521+
} else {
522+
SecondSlideCost = getRISCVInstructionCost(RISCV::VMERGE_VVM, LT.second, CostKind);
523+
}
524+
525+
auto EC = Tp->getElementCount();
526+
VectorType *MaskTy = VectorType::get(IntegerType::getInt1Ty(Tp->getContext()), EC);
527+
InstructionCost MaskCost = getConstantPoolLoadCost(MaskTy, CostKind);
528+
return FirstSlideCost + SecondSlideCost + MaskCost;
529+
}
530+
477531
InstructionCost RISCVTTIImpl::getShuffleCost(TTI::ShuffleKind Kind,
478532
VectorType *Tp, ArrayRef<int> Mask,
479533
TTI::TargetCostKind CostKind,
@@ -487,8 +541,8 @@ InstructionCost RISCVTTIImpl::getShuffleCost(TTI::ShuffleKind Kind,
487541
// First, handle cases where having a fixed length vector enables us to
488542
// give a more accurate cost than falling back to generic scalable codegen.
489543
// TODO: Each of these cases hints at a modeling gap around scalable vectors.
490-
if (ST->hasVInstructions() && isa<FixedVectorType>(Tp) &&
491-
LT.second.isFixedLengthVector()) {
544+
if (auto *FVTp = dyn_cast<FixedVectorType>(Tp);
545+
FVTp && ST->hasVInstructions() && LT.second.isFixedLengthVector()) {
492546
InstructionCost VRegSplittingCost = costShuffleViaVRegSplitting(
493547
*this, LT.second, ST->getRealVLen(), Tp, Mask, CostKind);
494548
if (VRegSplittingCost.isValid())
@@ -544,6 +598,11 @@ InstructionCost RISCVTTIImpl::getShuffleCost(TTI::ShuffleKind Kind,
544598
return Cost;
545599
}
546600
}
601+
602+
if (InstructionCost SlideCost = getSlideCost(FVTp, Mask, CostKind);
603+
SlideCost.isValid())
604+
return SlideCost;
605+
547606
// vrgather + cost of generating the mask constant.
548607
// We model this for an unknown mask with a single vrgather.
549608
if (LT.first == 1 && (LT.second.getScalarSizeInBits() != 8 ||
@@ -558,6 +617,11 @@ InstructionCost RISCVTTIImpl::getShuffleCost(TTI::ShuffleKind Kind,
558617
}
559618
case TTI::SK_Transpose:
560619
case TTI::SK_PermuteTwoSrc: {
620+
621+
if (InstructionCost SlideCost = getSlideCost(FVTp, Mask, CostKind);
622+
SlideCost.isValid())
623+
return SlideCost;
624+
561625
// 2 x (vrgather + cost of generating the mask constant) + cost of mask
562626
// register for the second vrgather. We model this for an unknown
563627
// (shuffle) mask.

llvm/lib/Target/RISCV/RISCVTargetTransformInfo.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,12 @@ class RISCVTTIImpl : public BasicTTIImplBase<RISCVTTIImpl> {
6363
/// type.
6464
InstructionCost getConstantPoolLoadCost(Type *Ty,
6565
TTI::TargetCostKind CostKind);
66+
67+
/// If this shuffle can be lowered as a masked slide pair (at worst),
68+
/// return a cost for it.
69+
InstructionCost getSlideCost(FixedVectorType *Tp, ArrayRef<int> Mask,
70+
TTI::TargetCostKind CostKind);
71+
6672
public:
6773
explicit RISCVTTIImpl(const RISCVTargetMachine *TM, const Function &F)
6874
: BaseT(TM, F.getDataLayout()), ST(TM->getSubtargetImpl(F)),

llvm/test/Analysis/CostModel/RISCV/shuffle-exact-vlen.ll

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ define void @insert_subvec() vscale_range(2,2) {
186186
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: %v16i32_4_1 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 16, i32 17, i32 18, i32 19, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15>
187187
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: %v16i32_4_2 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 16, i32 17, i32 18, i32 19, i32 12, i32 13, i32 14, i32 15>
188188
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: %v16i32_4_3 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 16, i32 17, i32 18, i32 19>
189-
; CHECK-NEXT: Cost Model: Found an estimated cost of 12 for instruction: %v16i32_4_05 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 16, i32 17, i32 18, i32 19, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15>
189+
; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %v16i32_4_05 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 16, i32 17, i32 18, i32 19, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15>
190190
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: ret void
191191
;
192192
; CHECK-SIZE-LABEL: 'insert_subvec'
@@ -225,7 +225,7 @@ define void @insert_subvec() vscale_range(2,2) {
225225
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 0 for instruction: %v16i32_4_1 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 16, i32 17, i32 18, i32 19, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15>
226226
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 0 for instruction: %v16i32_4_2 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 16, i32 17, i32 18, i32 19, i32 12, i32 13, i32 14, i32 15>
227227
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 0 for instruction: %v16i32_4_3 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 16, i32 17, i32 18, i32 19>
228-
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 12 for instruction: %v16i32_4_05 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 16, i32 17, i32 18, i32 19, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15>
228+
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %v16i32_4_05 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 16, i32 17, i32 18, i32 19, i32 6, i32 7, i32 8, i32 9, i32 10, i32 11, i32 12, i32 13, i32 14, i32 15>
229229
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret void
230230
;
231231
%v4i8_2_0 = shufflevector <4 x i8> poison, <4 x i8> poison, <4 x i32> <i32 0, i32 1, i32 6, i32 7>
@@ -737,8 +737,8 @@ define void @multipart() vscale_range(2,2) {
737737
; CHECK-NEXT: Cost Model: Found an estimated cost of 1 for instruction: %v16b = shufflevector <8 x i16> poison, <8 x i16> poison, <8 x i32> <i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1>
738738
; CHECK-NEXT: Cost Model: Found an estimated cost of 12 for instruction: %v16c = shufflevector <16 x i16> poison, <16 x i16> poison, <16 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1>
739739
; CHECK-NEXT: Cost Model: Found an estimated cost of 12 for instruction: %v16d = shufflevector <16 x i16> poison, <16 x i16> poison, <16 x i32> <i32 0, i32 16, i32 1, i32 17, i32 2, i32 18, i32 3, i32 19, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1>
740-
; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %v32a = shufflevector <4 x i32> poison, <4 x i32> poison, <4 x i32> <i32 2, i32 3, i32 0, i32 1>
741-
; CHECK-NEXT: Cost Model: Found an estimated cost of 16 for instruction: %v32a4 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1>
740+
; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %v32a = shufflevector <4 x i32> poison, <4 x i32> poison, <4 x i32> <i32 2, i32 3, i32 0, i32 1>
741+
; CHECK-NEXT: Cost Model: Found an estimated cost of 20 for instruction: %v32a4 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1>
742742
; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v32idrev = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 15, i32 14, i32 13, i32 12, i32 16, i32 17, i32 18, i32 19, i32 31, i32 30, i32 29, i32 28>
743743
; CHECK-NEXT: Cost Model: Found an estimated cost of 47 for instruction: %v32many = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 4, i32 8, i32 12, i32 16, i32 20, i32 24, i32 28, i32 2, i32 6, i32 10, i32 14, i32 18, i32 22, i32 26, i32 30>
744744
; CHECK-NEXT: Cost Model: Found an estimated cost of 47 for instruction: %v32many2 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 1, i32 4, i32 8, i32 12, i32 17, i32 20, i32 24, i32 28, i32 2, i32 6, i32 11, i32 14, i32 18, i32 22, i32 27, i32 30>
@@ -757,8 +757,8 @@ define void @multipart() vscale_range(2,2) {
757757
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 1 for instruction: %v16b = shufflevector <8 x i16> poison, <8 x i16> poison, <8 x i32> <i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1>
758758
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 12 for instruction: %v16c = shufflevector <16 x i16> poison, <16 x i16> poison, <16 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1>
759759
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 12 for instruction: %v16d = shufflevector <16 x i16> poison, <16 x i16> poison, <16 x i32> <i32 0, i32 16, i32 1, i32 17, i32 2, i32 18, i32 3, i32 19, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1>
760-
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %v32a = shufflevector <4 x i32> poison, <4 x i32> poison, <4 x i32> <i32 2, i32 3, i32 0, i32 1>
761-
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 16 for instruction: %v32a4 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1>
760+
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %v32a = shufflevector <4 x i32> poison, <4 x i32> poison, <4 x i32> <i32 2, i32 3, i32 0, i32 1>
761+
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 20 for instruction: %v32a4 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1, i32 2, i32 3, i32 0, i32 1>
762762
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v32idrev = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 1, i32 2, i32 3, i32 15, i32 14, i32 13, i32 12, i32 16, i32 17, i32 18, i32 19, i32 31, i32 30, i32 29, i32 28>
763763
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 11 for instruction: %v32many = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 0, i32 4, i32 8, i32 12, i32 16, i32 20, i32 24, i32 28, i32 2, i32 6, i32 10, i32 14, i32 18, i32 22, i32 26, i32 30>
764764
; CHECK-SIZE-NEXT: Cost Model: Found an estimated cost of 11 for instruction: %v32many2 = shufflevector <16 x i32> poison, <16 x i32> poison, <16 x i32> <i32 1, i32 4, i32 8, i32 12, i32 17, i32 20, i32 24, i32 28, i32 2, i32 6, i32 11, i32 14, i32 18, i32 22, i32 27, i32 30>

llvm/test/Analysis/CostModel/RISCV/shuffle-extract_subvector.ll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ define void @test_vXf64(<4 x double> %src256, <8 x double> %src512) {
1919
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: %V512_0123 = shufflevector <8 x double> %src512, <8 x double> undef, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
2020
; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V512_2345 = shufflevector <8 x double> %src512, <8 x double> undef, <4 x i32> <i32 2, i32 3, i32 4, i32 5>
2121
; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V512_4567 = shufflevector <8 x double> %src512, <8 x double> undef, <4 x i32> <i32 4, i32 5, i32 6, i32 7>
22-
; CHECK-NEXT: Cost Model: Found an estimated cost of 19 for instruction: %V512_567u = shufflevector <8 x double> %src512, <8 x double> undef, <4 x i32> <i32 5, i32 6, i32 7, i32 poison>
22+
; CHECK-NEXT: Cost Model: Found an estimated cost of 4 for instruction: %V512_567u = shufflevector <8 x double> %src512, <8 x double> undef, <4 x i32> <i32 5, i32 6, i32 7, i32 poison>
2323
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: ret void
2424
;
2525
; VLEN128-LABEL: 'test_vXf64'

0 commit comments

Comments
 (0)