Home | History | Annotate | Download | only in InstCombine

Lines Matching full:bitwidth

55   unsigned BitWidth = Inst.getType()->getScalarSizeInBits();
56 APInt KnownZero(BitWidth, 0), KnownOne(BitWidth, 0);
57 APInt DemandedMask(APInt::getAllOnesValue(BitWidth));
94 /// in DemandedMask. Note also that the bitwidth of V, DemandedMask, KnownZero
107 uint32_t BitWidth = DemandedMask.getBitWidth();
111 assert((!DL || DL->getTypeSizeInBits(VTy->getScalarType()) == BitWidth) &&
113 VTy->getScalarSizeInBits() == BitWidth) &&
114 KnownZero.getBitWidth() == BitWidth &&
115 KnownOne.getBitWidth() == BitWidth &&
117 "must have same BitWidth");
142 APInt LHSKnownZero(BitWidth, 0), LHSKnownOne(BitWidth, 0);
143 APInt RHSKnownZero(BitWidth, 0), RHSKnownOne(BitWidth, 0);
229 DemandedMask = APInt::getAllOnesValue(BitWidth);
405 DemandedMask = DemandedMask.trunc(BitWidth);
406 KnownZero = KnownZero.trunc(BitWidth);
407 KnownOne = KnownOne.trunc(BitWidth);
443 DemandedMask = DemandedMask.zext(BitWidth);
444 KnownZero = KnownZero.zext(BitWidth);
445 KnownOne = KnownOne.zext(BitWidth);
448 KnownZero |= APInt::getHighBitsSet(BitWidth, BitWidth - SrcBitWidth);
456 APInt::getLowBitsSet(BitWidth, SrcBitWidth);
458 APInt NewBits(APInt::getHighBitsSet(BitWidth, BitWidth - SrcBitWidth));
470 InputDemandedBits = InputDemandedBits.zext(BitWidth);
471 KnownZero = KnownZero.zext(BitWidth);
472 KnownOne = KnownOne.zext(BitWidth);
505 APInt InDemandedBits(APInt::getLowBitsSet(BitWidth, BitWidth - NLZ));
554 if (DemandedMask[BitWidth-1] == 0) {
557 APInt DemandedFromOps(APInt::getLowBitsSet(BitWidth, BitWidth-NLZ));
570 if (DemandedMask[BitWidth-1] == 0) {
574 APInt DemandedFromOps(APInt::getLowBitsSet(BitWidth, BitWidth-NLZ));
609 uint64_t ShiftAmt = SA->getLimitedValue(BitWidth-1);
615 DemandedMaskIn |= APInt::getHighBitsSet(BitWidth, ShiftAmt+1);
617 DemandedMaskIn |= APInt::getHighBitsSet(BitWidth, ShiftAmt);
627 KnownZero |= APInt::getLowBitsSet(BitWidth, ShiftAmt);
633 uint64_t ShiftAmt = SA->getLimitedValue(BitWidth-1);
641 DemandedMaskIn |= APInt::getLowBitsSet(BitWidth, ShiftAmt);
651 APInt HighBits(APInt::getHighBitsSet(BitWidth, ShiftAmt));
674 uint32_t ShiftAmt = SA->getLimitedValue(BitWidth-1);
681 DemandedMaskIn.setBit(BitWidth-1);
686 DemandedMaskIn |= APInt::getLowBitsSet(BitWidth, ShiftAmt);
693 APInt HighBits(APInt::getHighBitsSet(BitWidth, ShiftAmt));
698 APInt SignBit(APInt::getSignBit(BitWidth));
704 if (BitWidth <= ShiftAmt || KnownZero[BitWidth-ShiftAmt-1] ||
728 APInt Mask2 = LowBits | APInt::getSignBit(BitWidth);
739 if (LHSKnownZero[BitWidth-1] || ((LHSKnownZero & LowBits) == LowBits))
744 if (LHSKnownOne[BitWidth-1] && ((LHSKnownOne & LowBits) != 0))
754 APInt LHSKnownZero(BitWidth, 0), LHSKnownOne(BitWidth, 0);
762 APInt KnownZero2(BitWidth, 0), KnownOne2(BitWidth, 0);
763 APInt AllOnes = APInt::getAllOnesValue(BitWidth);
773 KnownZero = APInt::getHighBitsSet(BitWidth, Leaders) & DemandedMask;
792 if (BitWidth-NLZ-NTZ == 8) {
794 unsigned InputBit = BitWidth-NTZ-8;
855 unsigned BitWidth = Ty->getIntegerBitWidth();
856 if (ShlOp1.uge(BitWidth) || ShrOp1.uge(BitWidth))
866 APInt BitMask1(APInt::getAllOnesValue(BitWidth));
867 APInt BitMask2(APInt::getAllOnesValue(BitWidth));