Home
last modified time | relevance | path

Searched refs:NumSrcElts (Results 1 – 19 of 19) sorted by relevance

/freebsd/contrib/llvm-project/llvm/include/llvm/SandboxIR/
H A DInstruction.h613 static bool isSingleSourceMask(ArrayRef<int> Mask, int NumSrcElts) { in isSingleSourceMask() argument
614 return llvm::ShuffleVectorInst::isSingleSourceMask(Mask, NumSrcElts); in isSingleSourceMask()
616 static bool isSingleSourceMask(const Constant *Mask, int NumSrcElts) { in isSingleSourceMask() argument
618 cast<llvm::Constant>(Mask->Val), NumSrcElts); in isSingleSourceMask()
633 static bool isIdentityMask(ArrayRef<int> Mask, int NumSrcElts) { in isIdentityMask() argument
634 return llvm::ShuffleVectorInst::isIdentityMask(Mask, NumSrcElts); in isIdentityMask()
636 static bool isIdentityMask(const Constant *Mask, int NumSrcElts) { in isIdentityMask() argument
638 cast<llvm::Constant>(Mask->Val), NumSrcElts); in isIdentityMask()
676 static bool isSelectMask(ArrayRef<int> Mask, int NumSrcElts) { in isSelectMask() argument
677 return llvm::ShuffleVectorInst::isSelectMask(Mask, NumSrcElts); in isSelectMask()
[all …]
/freebsd/contrib/llvm-project/llvm/lib/Transforms/Vectorize/
H A DVectorCombine.cpp927 unsigned NumSrcElts = SrcTy->getPrimitiveSizeInBits() / DestEltSize; in foldBitcastShuffle() local
929 FixedVectorType::get(DestTy->getScalarType(), NumSrcElts); in foldBitcastShuffle()
1998 unsigned NumSrcElts = BinOpTy->getNumElements(); in foldPermuteOfBinops() local
2003 any_of(OuterMask, [NumSrcElts](int M) { return M >= (int)NumSrcElts; })) in foldPermuteOfBinops()
2009 if (M < 0 || M >= (int)NumSrcElts) { in foldPermuteOfBinops()
2113 unsigned NumSrcElts = BinOpTy->getNumElements(); in foldShuffleOfBinops() local
2119 auto ConvertToUnary = [NumSrcElts](int &M) { in foldShuffleOfBinops()
2120 if (M >= (int)NumSrcElts) in foldShuffleOfBinops()
2121 M -= NumSrcElts; in foldShuffleOfBinops()
2160 [NumSrcElts](int M) { return M < (int)NumSrcElts; })) { in foldShuffleOfBinops()
[all …]
H A DSLPVectorizer.cpp5727 int NumSrcElts = Tp->getElementCount().getKnownMinValue(); local
5730 Mask, NumSrcElts, NumSubElts, Index)) {
5731 if (Index + NumSubElts > NumSrcElts &&
5732 Index + NumSrcElts <= static_cast<int>(Mask.size()))
/freebsd/contrib/llvm-project/llvm/lib/IR/
H A DInstructions.cpp1929 bool ShuffleVectorInst::isSingleSourceMask(ArrayRef<int> Mask, int NumSrcElts) { in isSingleSourceMask() argument
1932 return isSingleSourceMaskImpl(Mask, NumSrcElts); in isSingleSourceMask()
1947 bool ShuffleVectorInst::isIdentityMask(ArrayRef<int> Mask, int NumSrcElts) { in isIdentityMask() argument
1948 if (Mask.size() != static_cast<unsigned>(NumSrcElts)) in isIdentityMask()
1952 return isIdentityMaskImpl(Mask, NumSrcElts); in isIdentityMask()
1955 bool ShuffleVectorInst::isReverseMask(ArrayRef<int> Mask, int NumSrcElts) { in isReverseMask() argument
1956 if (Mask.size() != static_cast<unsigned>(NumSrcElts)) in isReverseMask()
1958 if (!isSingleSourceMask(Mask, NumSrcElts)) in isReverseMask()
1962 if (NumSrcElts < 2) in isReverseMask()
1968 if (Mask[I] != (NumSrcElts - 1 - I) && in isReverseMask()
[all …]
H A DAutoUpgrade.cpp3110 unsigned NumSrcElts = 128 / EltTy->getPrimitiveSizeInBits(); in upgradeX86IntrinsicCall() local
3111 auto *VT = FixedVectorType::get(EltTy, NumSrcElts); in upgradeX86IntrinsicCall()
3113 if (NumSrcElts == 2) in upgradeX86IntrinsicCall()
3142 unsigned NumSrcElts = cast<FixedVectorType>(CI->getArgOperand(0)->getType()) in upgradeX86IntrinsicCall() local
3149 ShuffleMask[i] = i % NumSrcElts; in upgradeX86IntrinsicCall()
/freebsd/contrib/llvm-project/llvm/include/llvm/IR/
H A DInstructions.h2038 LLVM_ABI static bool isSingleSourceMask(ArrayRef<int> Mask, int NumSrcElts);
2039 static bool isSingleSourceMask(const Constant *Mask, int NumSrcElts) {
2043 return isSingleSourceMask(MaskAsInts, NumSrcElts);
2060 LLVM_ABI static bool isIdentityMask(ArrayRef<int> Mask, int NumSrcElts);
2061 static bool isIdentityMask(const Constant *Mask, int NumSrcElts) {
2071 return isIdentityMask(MaskAsInts, NumSrcElts);
2108 LLVM_ABI static bool isSelectMask(ArrayRef<int> Mask, int NumSrcElts);
2109 static bool isSelectMask(const Constant *Mask, int NumSrcElts) {
2113 return isSelectMask(MaskAsInts, NumSrcElts);
2133 LLVM_ABI static bool isReverseMask(ArrayRef<int> Mask, int NumSrcElts);
[all …]
/freebsd/contrib/llvm-project/llvm/lib/Analysis/
H A DVectorUtils.cpp635 unsigned NumSrcElts = Mask.size(); in scaleShuffleMaskElts() local
636 assert(NumSrcElts > 0 && NumDstElts > 0 && "Unexpected scaling factor"); in scaleShuffleMaskElts()
639 if (NumSrcElts == NumDstElts) { in scaleShuffleMaskElts()
645 assert(((NumSrcElts % NumDstElts) == 0 || (NumDstElts % NumSrcElts) == 0) && in scaleShuffleMaskElts()
648 if (NumSrcElts > NumDstElts) { in scaleShuffleMaskElts()
649 int Scale = NumSrcElts / NumDstElts; in scaleShuffleMaskElts()
653 int Scale = NumDstElts / NumSrcElts; in scaleShuffleMaskElts()
H A DConstantFolding.cpp80 unsigned NumSrcElts, in foldConstVectorToAPInt() argument
85 for (unsigned i = 0; i != NumSrcElts; ++i) { in foldConstVectorToAPInt()
88 Element = C->getAggregateElement(NumSrcElts - i - 1); in foldConstVectorToAPInt()
122 unsigned NumSrcElts = cast<FixedVectorType>(VTy)->getNumElements(); in FoldBitCast() local
130 IntegerType::get(C->getContext(), FPWidth), NumSrcElts); in FoldBitCast()
137 SrcEltTy, NumSrcElts, DL)) in FoldBitCast()
/freebsd/contrib/llvm-project/llvm/include/llvm/CodeGen/
H A DBasicTTIImpl.h269 static bool isSplatMask(ArrayRef<int> Mask, unsigned NumSrcElts, int &Index) { in isSplatMask() argument
276 if (static_cast<unsigned>(P.value()) >= NumSrcElts * 2) in isSplatMask()
1109 int NumSrcElts = SrcTy->getElementCount().getKnownMinValue(); in improveShuffleKindFromMask() local
1112 if (ShuffleVectorInst::isReverseMask(Mask, NumSrcElts)) in improveShuffleKindFromMask()
1114 if (ShuffleVectorInst::isZeroEltSplatMask(Mask, NumSrcElts)) in improveShuffleKindFromMask()
1116 if (isSplatMask(Mask, NumSrcElts, Index)) in improveShuffleKindFromMask()
1118 if (ShuffleVectorInst::isExtractSubvectorMask(Mask, NumSrcElts, Index) && in improveShuffleKindFromMask()
1119 (Index + NumDstElts) <= NumSrcElts) { in improveShuffleKindFromMask()
1126 if (all_of(Mask, [NumSrcElts](int M) { return M < NumSrcElts; })) in improveShuffleKindFromMask()
1131 Mask, NumSrcElts, NumSubElts, Index)) { in improveShuffleKindFromMask()
[all …]
/freebsd/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/
H A DTargetLowering.cpp738 unsigned NumSrcElts = SrcVT.getVectorNumElements(); in SimplifyMultipleUseDemandedBits() local
740 APInt DemandedSrcElts = APInt::getZero(NumSrcElts); in SimplifyMultipleUseDemandedBits()
761 unsigned NumSrcElts = SrcVT.isVector() ? SrcVT.getVectorNumElements() : 1; in SimplifyMultipleUseDemandedBits() local
763 APInt DemandedSrcElts = APInt::getZero(NumSrcElts); in SimplifyMultipleUseDemandedBits()
1361 unsigned NumSrcElts = Src.getValueType().getVectorNumElements(); in SimplifyDemandedBits() local
1362 APInt DemandedSrcElts = DemandedElts.zext(NumSrcElts).shl(Idx); in SimplifyDemandedBits()
2716 unsigned NumSrcElts = SrcEltCnt.getFixedValue(); in SimplifyDemandedBits() local
2717 APInt DemandedSrcElts = APInt::getAllOnes(NumSrcElts); in SimplifyDemandedBits()
2719 if (CIdx->getAPIntValue().ult(NumSrcElts)) in SimplifyDemandedBits()
2720 DemandedSrcElts = APInt::getOneBitSet(NumSrcElts, CIdx->getZExtValue()); in SimplifyDemandedBits()
[all …]
H A DSelectionDAG.cpp3112 unsigned NumSrcElts = Src.getValueType().getVectorNumElements(); in isSplatValue() local
3114 APInt DemandedSrcElts = DemandedElts.zext(NumSrcElts).shl(Idx); in isSplatValue()
3129 unsigned NumSrcElts = Src.getValueType().getVectorNumElements(); in isSplatValue() local
3131 APInt DemandedSrcElts = DemandedElts.zext(NumSrcElts); in isSplatValue()
3153 unsigned NumSrcElts = SrcVT.getVectorNumElements(); in isSplatValue() local
3155 APIntOps::ScaleBitMask(DemandedElts, NumSrcElts); in isSplatValue()
3159 APInt SubDemandedElts = APInt::getSplat(NumSrcElts, SubDemandedElt); in isSplatValue()
3579 unsigned NumSrcElts = Src.getValueType().getVectorNumElements(); in computeKnownBits() local
3580 APInt DemandedSrcElts = DemandedElts.zext(NumSrcElts).shl(Idx); in computeKnownBits()
4237 const unsigned NumSrcElts = VecVT.getVectorNumElements(); in computeKnownBits() local
[all …]
H A DDAGCombiner.cpp22992 unsigned NumSrcElts = SubVecVT.getVectorNumElements(); in combineInsertEltToShuffle() local
22995 if (NumSrcElts == 1) in combineInsertEltToShuffle()
22998 unsigned NumMaskVals = ExtendRatio * NumSrcElts; in combineInsertEltToShuffle()
23007 if (i / NumSrcElts == InsIndex) in combineInsertEltToShuffle()
23008 Mask[i] = (i % NumSrcElts) + NumMaskVals; in combineInsertEltToShuffle()
26423 for (unsigned SrcElt = 0, NumSrcElts = NumElts / Scale; in combineShuffleToZeroExtendVectorInReg() local
26424 SrcElt != NumSrcElts; ++SrcElt) { in combineShuffleToZeroExtendVectorInReg()
/freebsd/contrib/llvm-project/llvm/lib/Transforms/InstCombine/
H A DInstCombineVectorOps.cpp229 ElementCount NumSrcElts = SrcTy->getElementCount(); in foldBitcastExtElt() local
230 if (NumSrcElts == NumElts) in foldBitcastExtElt()
234 assert(NumSrcElts.isScalable() == NumElts.isScalable() && in foldBitcastExtElt()
239 if (NumSrcElts.getKnownMinValue() < NumElts.getKnownMinValue()) { in foldBitcastExtElt()
252 NumElts.getKnownMinValue() / NumSrcElts.getKnownMinValue(); in foldBitcastExtElt()
/freebsd/contrib/llvm-project/llvm/lib/Target/X86/
H A DX86ISelLowering.cpp3925 unsigned NumSrcElts = Mask.size(); in scaleShuffleElements() local
3926 assert(((NumSrcElts % NumDstElts) == 0 || (NumDstElts % NumSrcElts) == 0) && in scaleShuffleElements()
3930 if (NumDstElts >= NumSrcElts) { in scaleShuffleElements()
3931 int Scale = NumDstElts / NumSrcElts; in scaleShuffleElements()
3964 unsigned NumSrcElts = SrcMask.size(); in growShuffleMask() local
3969 M = (M % NumSrcElts) + ((M / NumSrcElts) * Scale * NumSrcElts); in growShuffleMask()
3971 DstMask.append((Scale - 1) * NumSrcElts, SM_SentinelUndef); in growShuffleMask()
4203 unsigned NumSrcElts = VecVT.getVectorNumElements(); in widenSubVector() local
4204 ArrayRef<SDUse> Hi = Vec->ops().drop_front(NumSrcElts / 2); in widenSubVector()
5008 unsigned NumSrcElts = UndefSrcElts.getBitWidth(); in getTargetConstantBitsFromNode() local
[all …]
H A DX86InstCombineIntrinsic.cpp445 unsigned NumSrcElts = ArgTy->getNumElements(); in simplifyX86pack() local
446 assert(cast<FixedVectorType>(ResTy)->getNumElements() == (2 * NumSrcElts) && in simplifyX86pack()
449 unsigned NumSrcEltsPerLane = NumSrcElts / NumLanes; in simplifyX86pack()
491 PackMask.push_back(Elt + (Lane * NumSrcEltsPerLane) + NumSrcElts); in simplifyX86pack()
/freebsd/contrib/llvm-project/clang/lib/CodeGen/
H A DCGExpr.cpp2712 unsigned NumSrcElts = VTy->getNumElements(); in EmitStoreThroughExtVectorComponentLValue() local
2714 if (NumDstElts == NumSrcElts) { in EmitStoreThroughExtVectorComponentLValue()
2719 for (unsigned i = 0; i != NumSrcElts; ++i) in EmitStoreThroughExtVectorComponentLValue()
2723 } else if (NumDstElts > NumSrcElts) { in EmitStoreThroughExtVectorComponentLValue()
2729 for (unsigned i = 0; i != NumSrcElts; ++i) in EmitStoreThroughExtVectorComponentLValue()
2741 if (getAccessedFieldNo(NumSrcElts - 1, Elts) == Mask.size()) in EmitStoreThroughExtVectorComponentLValue()
2742 NumSrcElts--; in EmitStoreThroughExtVectorComponentLValue()
2745 for (unsigned i = 0; i != NumSrcElts; ++i) in EmitStoreThroughExtVectorComponentLValue()
/freebsd/contrib/llvm-project/llvm/lib/Target/ARM/
H A DARMISelLowering.cpp8326 unsigned NumSrcElts = VTSize / EltVT.getFixedSizeInBits(); in ReconstructShuffle() local
8327 EVT DestVT = EVT::getVectorVT(*DAG.getContext(), EltVT, NumSrcElts); in ReconstructShuffle()
8343 if (Src.MaxElt - Src.MinElt >= NumSrcElts) { in ReconstructShuffle()
8348 if (Src.MinElt >= NumSrcElts) { in ReconstructShuffle()
8352 DAG.getConstant(NumSrcElts, dl, MVT::i32)); in ReconstructShuffle()
8353 Src.WindowBase = -NumSrcElts; in ReconstructShuffle()
8354 } else if (Src.MaxElt < NumSrcElts) { in ReconstructShuffle()
8366 DAG.getConstant(NumSrcElts, dl, MVT::i32)); in ReconstructShuffle()
20076 const unsigned NumSrcElts = VecVT.getVectorNumElements(); in computeKnownBitsForTargetNode() local
20078 assert(Pos->getAPIntValue().ult(NumSrcElts) && in computeKnownBitsForTargetNode()
[all …]
/freebsd/contrib/llvm-project/llvm/lib/Target/AArch64/
H A DAArch64ISelLowering.cpp13070 unsigned NumSrcElts = VTSize / EltVT.getFixedSizeInBits(); in ReconstructShuffle() local
13071 EVT DestVT = EVT::getVectorVT(*DAG.getContext(), EltVT, NumSrcElts); in ReconstructShuffle()
13089 if (Src.MaxElt - Src.MinElt >= NumSrcElts) { in ReconstructShuffle()
13095 if (Src.MinElt >= NumSrcElts) { in ReconstructShuffle()
13099 DAG.getConstant(NumSrcElts, DL, MVT::i64)); in ReconstructShuffle()
13100 Src.WindowBase = -NumSrcElts; in ReconstructShuffle()
13101 } else if (Src.MaxElt < NumSrcElts) { in ReconstructShuffle()
13113 DAG.getConstant(NumSrcElts, DL, MVT::i64)); in ReconstructShuffle()
/freebsd/contrib/llvm-project/llvm/lib/CodeGen/GlobalISel/
H A DLegalizerHelper.cpp5198 unsigned NumSrcElts = SrcTy.isVector() ? SrcTy.getNumElements() : 1; in fewerElementsVectorMerge() local
5199 unsigned NumElts = NarrowTy.getNumElements() / NumSrcElts; in fewerElementsVectorMerge()