/external/llvm/unittests/ADT/ |
H A D | APIntTest.cpp | 1 //===- llvm/unittest/ADT/APInt.cpp - APInt unit tests ---------------------===// 10 #include "llvm/ADT/APInt.h" 19 // Test that APInt shift left works when bitwidth > 64 and shiftamt == 0 21 APInt One = APInt::getNullValue(65) + 1; 22 APInt Shl = One.shl(0); 28 APInt Minus3(128, static_cast<uint64_t>(-3), true); 32 APInt Minus1(128, static_cast<uint64_t>(-1), true); 46 APInt i33minus [all...] |
/external/llvm/include/llvm/ADT/ |
H A D | APInt.h | 1 //===-- llvm/ADT/APInt.h - For Arbitrary Precision Integer -----*- C++ -*--===// 46 // APInt Class 51 /// APInt is a functional replacement for common case unsigned integer type like 54 /// than 64-bits of precision. APInt provides a variety of arithmetic operators 63 /// * All binary operators must be on APInt instances of the same bit width. 75 class APInt { class in namespace:llvm 76 unsigned BitWidth; ///< The number of bits in this APInt. 85 /// This enum is used to hold the constants we needed for APInt. 98 APInt(uint64_t *val, unsigned bits) : BitWidth(bits), pVal(val) {} function in class:llvm::APInt 100 /// \brief Determine if this APInt jus 236 APInt(unsigned numBits, uint64_t val, bool isSigned = false) function in class:llvm::APInt 279 APInt(const APInt &that) : BitWidth(that.BitWidth), VAL(0) { function in class:llvm::APInt 289 APInt(APInt &&that) : BitWidth(that.BitWidth), VAL(that.VAL) { function in class:llvm::APInt 304 explicit APInt() : BitWidth(1) {} function in class:llvm::APInt [all...] |
H A D | APSInt.h | 18 #include "llvm/ADT/APInt.h" 22 class APSInt : public APInt { 25 /// Default constructor that creates an uninitialized APInt. 31 : APInt(BitWidth, 0), IsUnsigned(isUnsigned) {} 33 explicit APSInt(const APInt &I, bool isUnsigned = true) 34 : APInt(I), IsUnsigned(isUnsigned) {} 37 APInt::operator=(RHS); 42 APSInt &operator=(const APInt &RHS) { 44 APInt::operator=(RHS); 50 APInt [all...] |
H A D | APFloat.h | 20 #include "llvm/ADT/APInt.h" 43 /// the APInt class. The library will work with bignum integers whose parts are 195 APFloat(const fltSemantics &, const APInt &); 235 APInt fill(64, type); 244 const APInt *payload = 0) { 250 const APInt *payload = 0) { 324 opStatus convertFromAPInt(const APInt &, bool, roundingMode); 330 APInt bitcastToAPInt() const; 501 void makeNaN(bool SNaN = false, bool Neg = false, const APInt *fill = 0); 503 const APInt *fil [all...] |
/external/llvm/unittests/Support/ |
H A D | ConstantRangeTest.cpp | 29 ConstantRange ConstantRangeTest::One(APInt(16, 0xa)); 30 ConstantRange ConstantRangeTest::Some(APInt(16, 0xa), APInt(16, 0xaaa)); 31 ConstantRange ConstantRangeTest::Wrap(APInt(16, 0xaaa), APInt(16, 0xa)); 38 EXPECT_TRUE(Full.contains(APInt(16, 0x0))); 39 EXPECT_TRUE(Full.contains(APInt(16, 0x9))); 40 EXPECT_TRUE(Full.contains(APInt(16, 0xa))); 41 EXPECT_TRUE(Full.contains(APInt(16, 0xaa9))); 42 EXPECT_TRUE(Full.contains(APInt(1 [all...] |
H A D | IntegersSubsetTest.cpp | 11 #include "llvm/ADT/APInt.h" 20 class Int : public APInt { 23 Int(uint64_t V) : APInt(64, V) {} 24 Int(const APInt& Src) : APInt(Src) {} 25 bool operator < (const APInt& RHS) const { return ult(RHS); } 26 bool operator > (const APInt& RHS) const { return ugt(RHS); } 27 bool operator <= (const APInt& RHS) const { return ule(RHS); } 28 bool operator >= (const APInt& RHS) const { return uge(RHS); }
|
/external/llvm/lib/Support/ |
H A D | APSInt.cpp | 22 APInt::Profile(ID);
|
H A D | APInt.cpp | 1 //===-- APInt.cpp - Implement APInt class ---------------------------------===// 16 #include "llvm/ADT/APInt.h" 35 assert(result && "APInt memory allocation fails!"); 44 assert(result && "APInt memory allocation fails!"); 76 void APInt::initSlowCase(unsigned numBits, uint64_t val, bool isSigned) { 84 void APInt::initSlowCase(const APInt& that) { 89 void APInt::initFromArray(ArrayRef<uint64_t> bigVal) { 106 APInt function in class:APInt 111 APInt::APInt(unsigned numBits, unsigned numWords, const uint64_t bigVal[]) function in class:APInt 116 APInt::APInt(unsigned numbits, StringRef Str, uint8_t radix) function in class:APInt [all...] |
H A D | ConstantRange.cpp | 34 Lower = Upper = APInt::getMaxValue(BitWidth); 36 Lower = Upper = APInt::getMinValue(BitWidth); 67 APInt UMax(CR.getUnsignedMax()); 70 return ConstantRange(APInt::getMinValue(W), UMax); 73 APInt SMax(CR.getSignedMax()); 76 return ConstantRange(APInt::getSignedMinValue(W), SMax); 79 APInt UMax(CR.getUnsignedMax()); 82 return ConstantRange(APInt::getMinValue(W), UMax + 1); 85 APInt SMax(CR.getSignedMax()); 88 return ConstantRange(APInt [all...] |
H A D | APFloat.cpp | 347 lsb = APInt::tcLSB(parts, partCount); 355 APInt::tcExtractBit(parts, bits - 1)) 369 APInt::tcShiftRight(dst, parts, bits); 485 APInt::tcFullMultiply(pow5, pow5 - pc, pow5 - pc, pc, pc); 495 APInt::tcFullMultiply(p2, p1, pow5, result, pc); 509 APInt::tcAssign(dst, p1, result); 611 APInt::tcAssign(significandParts(), rhs.significandParts(), 618 void APFloat::makeNaN(bool SNaN, bool Negative, const APInt *fill) 628 APInt::tcSet(significand, 0, numParts); 630 APInt [all...] |
/external/llvm/include/llvm/Support/ |
H A D | ConstantRange.h | 35 #include "llvm/ADT/APInt.h" 43 APInt Lower, Upper; 47 typedef APInt APIntMoveTy; 50 typedef const APInt &APIntMoveTy; 64 /// assert out if the two APInt's are not the same bit width. 79 const APInt &getLower() const { return Lower; } 83 const APInt &getUpper() const { return Upper; } 110 bool contains(const APInt &Val) const; 119 const APInt *getSingleElement() const { 131 APInt getSetSiz [all...] |
H A D | IntegersSubset.h | 28 // The IntItem is a wrapper for APInt. 33 // 3. Currently we can interpret IntItem both as ConstantInt and as APInt. 35 // non-updated passes. And it allows to use APInt interface for new methods. 36 // 4. IntItem can be easily replaced with APInt. 38 // The set of macros that allows to propagate APInt operators to the IntItem. 41 bool operator op (const APInt& RHS) const { \ 47 APInt res = op(getAPIntValue()); \ 53 IntItem operator op (const APInt& RHS) const { \ 54 APInt res = getAPIntValue() op RHS; \ 60 IntItem& operator op (const APInt [all...] |
/external/clang/test/SemaCXX/ |
H A D | unused.cpp | 5 class APInt { class in namespace:PR4103 8 class APSInt : public APInt { 15 APInt::operator=(RHS);
|
/external/llvm/include/llvm/ExecutionEngine/ |
H A D | GenericValue.h | 18 #include "llvm/ADT/APInt.h" 24 class APInt; 38 APInt IntVal; // also used for long doubles.
|
/external/llvm/include/llvm/Analysis/ |
H A D | ValueTracking.h | 24 class APInt; 39 void ComputeMaskedBits(Value *V, APInt &KnownZero, APInt &KnownOne, 41 void computeMaskedBitsLoad(const MDNode &Ranges, APInt &KnownZero); 70 bool MaskedValueIsZero(Value *V, const APInt &Mask,
|
H A D | MemoryBuiltins.h | 151 typedef std::pair<APInt, APInt> SizeOffsetType; 162 APInt Zero; 165 APInt align(APInt Size, uint64_t Align); 168 return std::make_pair(APInt(), APInt());
|
H A D | PtrUseVisitor.h | 25 #include "llvm/ADT/APInt.h" 120 APInt Offset; 144 APInt Offset; 210 Offset = APInt(IntPtrTy->getBitWidth(), 0); 253 Offset = APInt();
|
/external/llvm/lib/Transforms/InstCombine/ |
H A D | InstCombineSimplifyDemanded.cpp | 29 APInt Demanded) { 55 APInt KnownZero(BitWidth, 0), KnownOne(BitWidth, 0); 56 APInt DemandedMask(APInt::getAllOnesValue(BitWidth)); 69 bool InstCombiner::SimplifyDemandedBits(Use &U, APInt DemandedMask, 70 APInt &KnownZero, APInt &KnownOne, 101 Value *InstCombiner::SimplifyDemandedUseBits(Value *V, APInt DemandedMask, 102 APInt &KnownZero, APInt [all...] |
H A D | InstCombine.h | 302 void ComputeMaskedBits(Value *V, APInt &KnownZero, 303 APInt &KnownOne, unsigned Depth = 0) const { 307 bool MaskedValueIsZero(Value *V, const APInt &Mask, 330 Value *SimplifyDemandedUseBits(Value *V, APInt DemandedMask, 331 APInt& KnownZero, APInt& KnownOne, 333 bool SimplifyDemandedBits(Use &U, APInt DemandedMask, 334 APInt& KnownZero, APInt& KnownOne, 339 APInt DemandedMas [all...] |
/external/llvm/include/llvm/IR/ |
H A D | Constant.h | 20 class APInt; 113 const APInt &getUniqueInteger() const; 159 static Constant *getIntegerValue(Type* Ty, const APInt &V);
|
/external/llvm/lib/Analysis/ |
H A D | ValueTracking.cpp | 47 APInt &KnownZero, APInt &KnownOne, 48 APInt &KnownZero2, APInt &KnownOne2, 59 APInt MaskV = APInt::getHighBitsSet(BitWidth, NLZ+1); 68 KnownZero = APInt::getHighBitsSet(BitWidth, NLZ2); 80 APInt LHSKnownZero(BitWidth, 0), LHSKnownOne(BitWidth, 0); 94 APInt Mask = APInt [all...] |
H A D | DependenceAnalysis.cpp | 35 // Subtract, or Multiply, with both APInt's and SCEV's. 499 APInt Xtop = C1B2_C2B1->getValue()->getValue(); 500 APInt Xbot = A1B2_A2B1->getValue()->getValue(); 501 APInt Ytop = C1A2_C2A1->getValue()->getValue(); 502 APInt Ybot = A2B1_A1B2->getValue()->getValue(); 507 APInt Xq = Xtop; // these need to be initialized, even 508 APInt Xr = Xtop; // though they're just going to be overwritten 509 APInt::sdivrem(Xtop, Xbot, Xq, Xr); 510 APInt Yq = Ytop; 511 APInt Y [all...] |
/external/llvm/examples/BrainF/ |
H A D | BrainF.cpp | 81 ConstantInt *val_mem = ConstantInt::get(C, APInt(32, memtotal)); 95 ConstantInt::get(C, APInt(8, 0)), 97 ConstantInt::get(C, APInt(32, 1)), 98 ConstantInt::get(C, APInt(1, 0)) 109 CreateGEP(ptr_arr, ConstantInt::get(C, APInt(32, memtotal)), "arrmax"); 114 ConstantInt::get(C, APInt(32, memtotal/2)), 241 CreateGEP(curhead, ConstantInt::get(C, APInt(32, curvalue)), 276 CreateAdd(tape_0, ConstantInt::get(C, APInt(8, curvalue)), tapereg); 440 ConstantInt::get(C, APInt(8, 0)), testreg);
|
/external/llvm/lib/ExecutionEngine/MCJIT/ |
H A D | MCJIT.cpp | 253 rv.IntVal = APInt(32, PF(ArgValues[0].IntVal.getZExtValue(), 266 rv.IntVal = APInt(32, PF(ArgValues[0].IntVal.getZExtValue(), 276 rv.IntVal = APInt(32, PF(ArgValues[0].IntVal.getZExtValue())); 291 rv.IntVal = APInt(BitWidth, ((bool(*)())(intptr_t)FPtr)()); 293 rv.IntVal = APInt(BitWidth, ((char(*)())(intptr_t)FPtr)()); 295 rv.IntVal = APInt(BitWidth, ((short(*)())(intptr_t)FPtr)()); 297 rv.IntVal = APInt(BitWidth, ((int(*)())(intptr_t)FPtr)()); 299 rv.IntVal = APInt(BitWidth, ((int64_t(*)())(intptr_t)FPtr)()); 305 rv.IntVal = APInt(32, ((int(*)())(intptr_t)FPtr)());
|
/external/llvm/lib/Target/NVPTX/ |
H A D | NVPTXMCExpr.cpp | 41 APInt API = APF.bitcastToAPInt();
|