/freebsd-11-stable/contrib/llvm-project/llvm/lib/Transforms/InstCombine/ |
H A D | InstCombineShifts.cpp | 561 auto NewInnerShift = [&](unsigned ShAmt) { 562 InnerShift->setOperand(1, ConstantInt::get(ShType, ShAmt)); 724 Constant *ShAmt = local 727 Value *NSh = Builder.CreateBinOp(I.getOpcode(), TrOp, ShAmt, I.getName()); 947 unsigned ShAmt = ShAmtAPInt->getZExtValue(); local 949 // shl (zext X), ShAmt --> zext (shl X, ShAmt) 954 if (ShAmt < SrcWidth && 955 MaskedValueIsZero(X, APInt::getHighBitsSet(SrcWidth, ShAmt), 0, &I)) 956 return new ZExtInst(Builder.CreateShl(X, ShAmt), T 1062 unsigned ShAmt = ShAmtAPInt->getZExtValue(); local 1261 unsigned ShAmt = ShAmtAPInt->getZExtValue(); local [all...] |
H A D | InstCombineCasts.cpp | 548 Value *ShAmt = matchShiftAmount(ShAmt0, ShAmt1, NarrowWidth); local 550 if (!ShAmt) { 551 ShAmt = matchShiftAmount(ShAmt1, ShAmt0, NarrowWidth); 554 if (!ShAmt) 565 // trunc (or (lshr ShVal, ShAmt), (shl ShVal, BitWidth - ShAmt)) 567 // llvm.fshl.i8(trunc(ShVal), trunc(ShVal), trunc(ShAmt)) 568 Value *NarrowShAmt = Builder.CreateTrunc(ShAmt, DestTy); 902 uint32_t ShAmt = KnownZeroMask.logBase2(); local 904 if (ShAmt) { 1412 Constant *ShAmt = ConstantInt::get(DestTy, DestBitSize - SrcBitSize); local 1440 unsigned ShAmt = CA->getZExtValue()+SrcDstSize-MidSize; local [all...] |
H A D | InstCombineAddSub.cpp | 1253 Constant *ShAmt = ConstantInt::get(Ty, ExtendAmt); local 1254 Value *NewShl = Builder.CreateShl(XorLHS, ShAmt, "sext"); 1255 return BinaryOperator::CreateAShr(NewShl, ShAmt); 1790 const APInt *ShAmt; local 1793 match(Op1Wide, m_LShr(m_Value(X), m_APInt(ShAmt))) && 1794 *ShAmt == BitWidth - 1) { 1805 match(Op1Wide, m_AShr(m_Value(X), m_APInt(ShAmt))) && 1806 *ShAmt == BitWidth - 1) { 2080 const APInt *ShAmt; local 2082 if (match(Op1, m_AShr(m_Value(A), m_APInt(ShAmt))) [all...] |
H A D | InstCombineAndOrXor.cpp | 1965 const APInt *ShAmt; local 1968 m_APInt(ShAmt))), 1970 *ShAmt == Ty->getScalarSizeInBits() - 1) { 2073 Value *ShAmt = matchShiftAmount(ShAmt0, ShAmt1, Width); local 2075 if (!ShAmt) { 2076 ShAmt = matchShiftAmount(ShAmt1, ShAmt0, Width); 2079 if (!ShAmt) 2086 return IntrinsicInst::Create(F, { ShVal, ShVal, ShAmt }); 2716 const APInt *ShAmt; local 2719 m_APInt(ShAmt))), 3223 const APInt *ShAmt; local [all...] |
H A D | InstCombineInternal.h | 962 Instruction *foldICmpShrConstConst(ICmpInst &I, Value *ShAmt, const APInt &C1, 964 Instruction *foldICmpShlConstConst(ICmpInst &I, Value *ShAmt, const APInt &C1,
|
H A D | InstCombineCompares.cpp | 2246 // icmp eq/ne (shr X, ShAmt), C --> icmp eq/ne (and X, HiMask), (C << ShAmt) 4249 unsigned ShAmt = (unsigned)Cst1->getLimitedValue(TypeBits); local 4250 if (ShAmt < TypeBits && ShAmt != 0) { 4254 APInt CmpVal = APInt::getOneBitSet(TypeBits, ShAmt); 4263 unsigned ShAmt = (unsigned)Cst1->getLimitedValue(TypeBits); local 4264 if (ShAmt < TypeBits && ShAmt != 0) { 4266 APInt AndVal = APInt::getLowBitsSet(TypeBits, TypeBits - ShAmt); 4275 uint64_t ShAmt = 0; local 4287 MaskV <<= ShAmt; local 4290 CmpV <<= ShAmt; local [all...] |
H A D | InstCombineSelect.cpp | 2302 Value *ShAmt; 2304 ShAmt = SA0; 2306 ShAmt = SA1; 2313 if (!match(Cond, m_OneUse(m_ICmp(Pred, m_Specific(ShAmt), m_ZeroInt()))) || 2319 bool IsFshl = (ShAmt == SA0 && ShiftOpcode0 == BinaryOperator::Shl) || 2320 (ShAmt == SA1 && ShiftOpcode1 == BinaryOperator::Shl); 2323 return IntrinsicInst::Create(F, { TVal, TVal, ShAmt });
|
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Target/RISCV/ |
H A D | RISCVISelDAGToDAG.cpp | 148 uint64_t ShAmt = cast<ConstantSDNode>(Op1.getNode())->getZExtValue(); local 150 if ((Mask | maskTrailingOnes<uint64_t>(ShAmt)) == 0xffffffff) { 152 CurDAG->getTargetConstant(ShAmt, SDLoc(Node), XLenVT);
|
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Target/Lanai/ |
H A D | LanaiISelLowering.cpp | 1243 SDValue ShAmt = Op.getOperand(2); local 1245 // Performs the following for (ShOpLo + (ShOpHi << 32)) << ShAmt: 1246 // LoBitsForHi = (ShAmt == 0) ? 0 : (ShOpLo >> (32-ShAmt)) 1247 // HiBitsForHi = ShOpHi << ShAmt 1248 // Hi = (ShAmt >= 32) ? (ShOpLo << (ShAmt-32)) : (LoBitsForHi | HiBitsForHi) 1249 // Lo = (ShAmt >= 32) ? 0 : (ShOpLo << ShAmt) 1253 DAG.getConstant(VTBits, dl, MVT::i32), ShAmt); 1291 SDValue ShAmt = Op.getOperand(2); local [all...] |
/freebsd-11-stable/contrib/llvm-project/llvm/lib/CodeGen/SelectionDAG/ |
H A D | TargetLowering.cpp | 1329 unsigned ShAmt = SA->getZExtValue(); local 1330 if (ShAmt == 0) 1333 // If this is ((X >>u C1) << ShAmt), see if we can simplify this into a 1338 if (!DemandedBits.intersects(APInt::getLowBitsSet(BitWidth, ShAmt))) { 1344 int Diff = ShAmt - C1; 1358 if (SimplifyDemandedBits(Op0, DemandedBits.lshr(ShAmt), DemandedElts, 1364 if ((ShAmt < DemandedBits.getActiveBits()) && 1374 if (ShAmt < InnerBits && DemandedBits.getActiveBits() <= InnerBits && 1377 if (!APInt(BitWidth, ShAmt).isIntN(ShTy.getSizeInBits())) 1381 TLO.DAG.getConstant(ShAmt, d 1426 unsigned ShAmt = SA->getZExtValue(); local 1492 unsigned ShAmt = SA->getZExtValue(); local 1813 SDValue ShAmt = Src.getOperand(1); local 1915 SDValue ShAmt = TLO.DAG.getConstant(ShVal, dl, VT); local 3158 const APInt &ShAmt = N0.getConstantOperandAPInt(1); local [all...] |
H A D | LegalizeVectorOps.cpp | 786 SDValue ShAmt = DAG.getConstant( 788 SDValue Lo = DAG.getNode(ISD::SRL, dl, WideVT, LoadVals[WideIdx], ShAmt); 795 ShAmt = DAG.getConstant( 799 DAG.getNode(ISD::SHL, dl, WideVT, LoadVals[WideIdx], ShAmt); 815 ShAmt = 818 Lo = DAG.getNode(ISD::SHL, dl, WideVT, Lo, ShAmt); 819 Lo = DAG.getNode(ISD::SRA, dl, WideVT, Lo, ShAmt);
|
H A D | DAGCombiner.cpp | 626 EVT &MemVT, unsigned ShAmt = 0); 2071 SDValue ShAmt = ShiftOp.getOperand(1); local 2072 ConstantSDNode *ShAmtC = isConstOrConstSplat(ShAmt); 2081 SDValue NewShift = DAG.getNode(ShOpcode, DL, VT, Not.getOperand(0), ShAmt); 3257 SDValue ShAmt = N1.getOperand(1); local 3258 ConstantSDNode *ShAmtC = isConstOrConstSplat(ShAmt); 3261 SDValue SRA = DAG.getNode(ISD::SRA, DL, VT, N1.getOperand(0), ShAmt); 3543 unsigned ShAmt = local 3545 assert(ShAmt < VT.getScalarSizeInBits() && 3549 DAG.getNode(ISD::SHL, DL, VT, N0, DAG.getConstant(ShAmt, D 4812 isLegalNarrowLdSt(LSBaseSDNode *LDST, ISD::LoadExtType ExtType, EVT &MemVT, unsigned ShAmt) argument 5712 SDValue ShAmt = DAG.getConstant(16, DL, getShiftAmountTy(VT)); local 8054 unsigned ShAmt = UnknownBits.countTrailingZeros(); local 8154 unsigned ShAmt = Cst->getZExtValue(); local 10123 SDValue ShAmt = N0.getOperand(1); local 10376 unsigned ShAmt = 0; local 15157 unsigned ShAmt = Imm.countTrailingZeros(); local 16678 ConstantSDNode *ShAmt = dyn_cast<ConstantSDNode>(Op1.getOperand(1)); local [all...] |
/freebsd-11-stable/contrib/llvm-project/llvm/lib/IR/ |
H A D | ConstantFold.cpp | 271 APInt ShAmt = Amt->getValue(); 273 if ((ShAmt & 7) != 0) 275 ShAmt.lshrInPlace(3); 278 if (ShAmt.uge(CSize - ByteStart)) 282 if (ShAmt.ule(CSize - (ByteStart + ByteSize))) 284 ByteStart + ShAmt.getZExtValue(), ByteSize); 294 APInt ShAmt = Amt->getValue(); 296 if ((ShAmt & 7) != 0) 298 ShAmt.lshrInPlace(3); 301 if (ShAmt [all...] |
H A D | ConstantRange.cpp | 276 ConstantRange ShAmt = Other.intersectWith( local 278 if (ShAmt.isEmptySet()) { 286 APInt ShAmtUMax = ShAmt.getUnsignedMax();
|
/freebsd-11-stable/contrib/llvm-project/clang/lib/Lex/ |
H A D | PPExpressions.cpp | 695 unsigned ShAmt = static_cast<unsigned>(RHS.Val.getLimitedValue()); local 696 if (ShAmt >= LHS.getBitWidth()) { 698 ShAmt = LHS.getBitWidth()-1; 700 Res = LHS.Val >> ShAmt;
|
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Target/ARM/ |
H A D | ARMISelDAGToDAG.cpp | 83 ARM_AM::ShiftOpc ShOpcVal, unsigned ShAmt); 502 unsigned ShAmt) { 509 (ShAmt == 2 || (Subtarget->isSwift() && ShAmt == 1)); 694 unsigned ShAmt = Log2_32(RHSC); local 696 Opc = CurDAG->getTargetConstant(ARM_AM::getAM2Opc(AddSub, ShAmt, 722 unsigned ShAmt = 0; local 732 ShAmt = Sh->getZExtValue(); 733 if (isShifterOpProfitable(Offset, ShOpcVal, ShAmt)) 736 ShAmt 500 isShifterOpProfitable(const SDValue &Shift, ARM_AM::ShiftOpc ShOpcVal, unsigned ShAmt) argument 801 unsigned ShAmt = 0; local 1437 unsigned ShAmt = 0; local [all...] |
H A D | ARMBaseInstrInfo.cpp | 4093 unsigned ShAmt = DefMI.getOperand(3).getImm(); local 4094 if (ShAmt == 0 || ShAmt == 2) 4124 unsigned ShAmt = DefMI.getOperand(3).getImm(); local 4125 if (ShAmt == 0 || ShAmt == 1 || ShAmt == 2 || ShAmt == 3) 4398 unsigned ShAmt = local 4400 if (ShAmt [all...] |
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Target/NVPTX/ |
H A D | NVPTXISelLowering.cpp | 1972 SDValue ShAmt = Op.getOperand(2); local 1981 SDValue Hi = DAG.getNode(Opc, dl, VT, ShOpHi, ShAmt); 1983 ShAmt); 1999 ShAmt); 2000 SDValue Tmp1 = DAG.getNode(ISD::SRL, dl, VT, ShOpLo, ShAmt); 2001 SDValue ExtraShAmt = DAG.getNode(ISD::SUB, dl, MVT::i32, ShAmt, 2007 SDValue Cmp = DAG.getSetCC(dl, MVT::i1, ShAmt, 2010 SDValue Hi = DAG.getNode(Opc, dl, VT, ShOpHi, ShAmt); 2033 SDValue ShAmt = Op.getOperand(2); local 2042 ShAmt); [all...] |
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Analysis/ |
H A D | ConstantFolding.cpp | 2356 unsigned ShAmt = C2->urem(BitWidth); local 2357 if (!ShAmt) 2361 unsigned LshrAmt = IsRight ? ShAmt : BitWidth - ShAmt; 2362 unsigned ShlAmt = !IsRight ? ShAmt : BitWidth - ShAmt;
|
H A D | InstructionSimplify.cpp | 1981 const APInt *ShAmt; local 1984 // and (shl X, ShAmt), Mask --> shl X, ShAmt 1985 if (match(Op0, m_Shl(m_Value(X), m_APInt(ShAmt))) && 1986 (~(*Mask)).lshr(*ShAmt).isNullValue()) 1990 // and (lshr X, ShAmt), Mask --> lshr X, ShAmt 1991 if (match(Op0, m_LShr(m_Value(X), m_APInt(ShAmt))) && 1992 (~(*Mask)).shl(*ShAmt).isNullValue()) 2069 match(Op0, m_c_Or(m_CombineAnd(m_NUWShl(m_Value(X), m_APInt(ShAmt)), [all...] |
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Target/PowerPC/ |
H A D | PPCInstrInfo.cpp | 3794 uint64_t ShAmt = Imm & (SpecialShift32 ? 0x1F : 0x3F); 3800 else if (!SetCR && ShAmt == 0 && !PostRA) { 3809 uint64_t SH = ShAmt == 0 ? 0 : RightShift ? 32 - ShAmt : ShAmt; 3810 uint64_t MB = RightShift ? ShAmt : 0; 3811 uint64_t ME = RightShift ? 31 : 31 - ShAmt; 3819 uint64_t SH = ShAmt == 0 ? 0 : RightShift ? 64 - ShAmt : ShAmt; [all...] |
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Target/ARM/MCTargetDesc/ |
H A D | ARMInstPrinter.cpp | 1322 unsigned ShAmt = MO3.getImm(); 1323 if (ShAmt) { 1324 assert(ShAmt <= 3 && "Not a valid Thumb2 addressing mode!"); 1325 O << ", lsl " << markup("<imm:") << "#" << ShAmt << markup(">");
|
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Support/ |
H A D | APInt.cpp | 2015 APInt APInt::sshl_ov(const APInt &ShAmt, bool &Overflow) const { 2016 Overflow = ShAmt.uge(getBitWidth()); 2021 Overflow = ShAmt.uge(countLeadingZeros()); 2023 Overflow = ShAmt.uge(countLeadingOnes()); 2025 return *this << ShAmt; 2028 APInt APInt::ushl_ov(const APInt &ShAmt, bool &Overflow) const { 2029 Overflow = ShAmt.uge(getBitWidth()); 2033 Overflow = ShAmt.ugt(countLeadingZeros()); 2035 return *this << ShAmt;
|
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Target/Hexagon/ |
H A D | HexagonLoopIdiomRecognition.cpp | 1424 Value *ShAmt = CIV, *ShVal = Op; local 1426 auto *ATy = cast<IntegerType>(ShAmt->getType()); 1435 ShAmt = upcast(CastMap, IRB, ShAmt, VTy); 1438 W = IRB.CreateShl(ShVal, ShAmt);
|
/freebsd-11-stable/contrib/llvm-project/llvm/lib/Transforms/Scalar/ |
H A D | SROA.cpp | 2134 uint64_t ShAmt = 8 * Offset; 2136 ShAmt = 8 * (DL.getTypeStoreSize(IntTy) - DL.getTypeStoreSize(Ty) - Offset); 2137 if (ShAmt) { 2138 V = IRB.CreateLShr(V, ShAmt, Name + ".shift"); 2163 uint64_t ShAmt = 8 * Offset; 2165 ShAmt = 8 * (DL.getTypeStoreSize(IntTy) - DL.getTypeStoreSize(Ty) - Offset); 2166 if (ShAmt) { 2167 V = IRB.CreateShl(V, ShAmt, Name + ".shift"); 2171 if (ShAmt || Ty->getBitWidth() < IntTy->getBitWidth()) { 2172 APInt Mask = ~Ty->getMask().zext(IntTy->getBitWidth()).shl(ShAmt); [all...] |