Lines Matching refs:APInt

13 #include "llvm/ADT/APInt.h"
359 bool constToInt(const Constant *C, APInt &Val) const;
360 const ConstantInt *intToConst(const APInt &Val) const;
365 bool evaluateCMPri(uint32_t Cmp, const RegisterSubReg &R1, const APInt &A2,
369 bool evaluateCMPii(uint32_t Cmp, const APInt &A1, const APInt &A2,
371 bool evaluateCMPpi(uint32_t Cmp, uint32_t Props, const APInt &A2,
382 bool evaluateANDri(const RegisterSubReg &R1, const APInt &A2,
384 bool evaluateANDii(const APInt &A1, const APInt &A2, APInt &Result);
387 bool evaluateORri(const RegisterSubReg &R1, const APInt &A2,
389 bool evaluateORii(const APInt &A1, const APInt &A2, APInt &Result);
392 bool evaluateXORri(const RegisterSubReg &R1, const APInt &A2,
394 bool evaluateXORii(const APInt &A1, const APInt &A2, APInt &Result);
399 bool evaluateZEXTi(const APInt &A1, unsigned Width, unsigned Bits,
400 APInt &Result);
403 bool evaluateSEXTi(const APInt &A1, unsigned Width, unsigned Bits,
404 APInt &Result);
409 bool evaluateCLBi(const APInt &A1, bool Zeros, bool Ones, APInt &Result);
412 bool evaluateCTBi(const APInt &A1, bool Zeros, bool Ones, APInt &Result);
418 bool evaluateEXTRACTi(const APInt &A1, unsigned Bits, unsigned Offset,
419 bool Signed, APInt &Result);
423 bool evaluateSplati(const APInt &A1, unsigned Bits, unsigned Count,
424 APInt &Result);
1093 APInt &Val) const {
1101 const ConstantInt *MachineConstEvaluator::intToConst(const APInt &Val) const {
1126 APInt A;
1145 const APInt &A2, const CellMap &Inputs, bool &Result) {
1153 APInt A;
1180 APInt A;
1197 bool MachineConstEvaluator::evaluateCMPii(uint32_t Cmp, const APInt &A1,
1198 const APInt &A2, bool &Result) {
1201 Result = !APInt::isSameValue(A1, A2);
1205 Result = APInt::isSameValue(A1, A2);
1209 if (APInt::isSameValue(A1, A2))
1219 APInt Zx1 = A1.zext(MaxW);
1220 APInt Zx2 = A2.zext(MaxW);
1229 APInt Sx1 = A1.sext(MaxW);
1230 APInt Sx2 = A2.sext(MaxW);
1239 const APInt &A2, bool &Result) {
1388 APInt A;
1401 const APInt &A2, const CellMap &Inputs, LatticeCell &Result) {
1418 APInt A, ResA;
1430 bool MachineConstEvaluator::evaluateANDii(const APInt &A1,
1431 const APInt &A2, APInt &Result) {
1455 APInt A;
1468 const APInt &A2, const CellMap &Inputs, LatticeCell &Result) {
1485 APInt A, ResA;
1497 bool MachineConstEvaluator::evaluateORii(const APInt &A1,
1498 const APInt &A2, APInt &Result) {
1520 APInt A;
1533 const APInt &A2, const CellMap &Inputs, LatticeCell &Result) {
1547 APInt A, XA;
1559 bool MachineConstEvaluator::evaluateXORii(const APInt &A1,
1560 const APInt &A2, APInt &Result) {
1574 APInt A, XA;
1586 bool MachineConstEvaluator::evaluateZEXTi(const APInt &A1, unsigned Width,
1587 unsigned Bits, APInt &Result) {
1591 APInt Mask = APInt::getLowBitsSet(Width, Bits);
1605 APInt A, XA;
1617 bool MachineConstEvaluator::evaluateSEXTi(const APInt &A1, unsigned Width,
1618 unsigned Bits, APInt &Result) {
1625 Result = APInt(Width, 0);
1628 // In C, shifts by 64 invoke undefined behavior: handle that case in APInt.
1648 // V is a 64-bit sign-extended value. Convert it to APInt of desired
1650 Result = APInt(Width, V, true);
1670 APInt A, CA;
1682 bool MachineConstEvaluator::evaluateCLBi(const APInt &A1, bool Zeros,
1683 bool Ones, APInt &Result) {
1692 Result = APInt(BW, static_cast<uint64_t>(Count), false);
1705 APInt A, CA;
1717 bool MachineConstEvaluator::evaluateCTBi(const APInt &A1, bool Zeros,
1718 bool Ones, APInt &Result) {
1727 Result = APInt(BW, static_cast<uint64_t>(Count), false);
1744 const Constant *C = intToConst(APInt(Width, 0, false));
1751 APInt A, CA;
1763 bool MachineConstEvaluator::evaluateEXTRACTi(const APInt &A1, unsigned Bits,
1764 unsigned Offset, bool Signed, APInt &Result) {
1769 Result = APInt(BW, 0);
1779 Result = APInt(BW, V, Signed);
1799 APInt A, SA;
1811 bool MachineConstEvaluator::evaluateSplati(const APInt &A1, unsigned Bits,
1812 unsigned Count, APInt &Result) {
1815 APInt LoBits = (Bits < BW) ? A1.trunc(Bits) : A1.zext(Bits);
1819 APInt Res(SW, 0, false);
1857 static APInt getCmpImm(unsigned Opc, unsigned OpX,
2050 APInt A(32, (1ull << B), false);
2100 APInt C;
2132 APInt C;
2157 APInt Zero(BW, 0, false);
2237 APInt A;
2466 APInt HexagonConstEvaluator::getCmpImm(unsigned Opc, unsigned OpX,
2506 return APInt(32, Val, Signed);
2525 SmallVector<APInt,4> LoVs(LN), HiVs(HN);
2540 APInt HV = HiVs[i].zext(64) << 32;
2542 APInt LV = LoVs[j].zext(64);
2609 APInt A2 = getCmpImm(Opc, 2, Src2);
2613 APInt A1 = getCmpImm(Opc, 1, Src1);
2619 APInt A2 = getCmpImm(Opc, 2, Src2);
2647 APInt A(32, Src2.getImm(), true);
2658 APInt A(32, Src2.getImm(), true);
2698 APInt A(W, V, true);
2893 APInt A;
3015 APInt A;
3044 APInt M1;
3049 APInt M1;