LLVM API Documentation
#include <APSInt.h>


Public Member Functions | |
| APSInt () | |
| Default constructor that creates an uninitialized APInt. | |
| APSInt (uint32_t BitWidth, bool isUnsigned=true) | |
| APSInt (const APInt &I, bool isUnsigned=true) | |
| APSInt & | operator= (const APSInt &RHS) |
| APSInt & | operator= (const APInt &RHS) |
| APSInt & | operator= (uint64_t RHS) |
| Assignment operator. | |
| bool | isSigned () const |
| bool | isUnsigned () const |
| void | setIsUnsigned (bool Val) |
| void | setIsSigned (bool Val) |
| void | toString (SmallVectorImpl< char > &Str, unsigned Radix=10) const |
| toString - Append this APSInt to the specified SmallString. | |
| std::string | toString (unsigned Radix) const |
| APSInt | trunc (uint32_t width) const |
| APSInt | extend (uint32_t width) const |
| APSInt | extOrTrunc (uint32_t width) const |
| const APSInt & | operator%= (const APSInt &RHS) |
| const APSInt & | operator/= (const APSInt &RHS) |
| APSInt | operator% (const APSInt &RHS) const |
| APSInt | operator/ (const APSInt &RHS) const |
| APSInt | operator>> (unsigned Amt) const |
| APSInt & | operator>>= (unsigned Amt) |
| bool | operator< (const APSInt &RHS) const |
| bool | operator> (const APSInt &RHS) const |
| bool | operator<= (const APSInt &RHS) const |
| bool | operator>= (const APSInt &RHS) const |
| bool | operator== (const APSInt &RHS) const |
| bool | operator== (int64_t RHS) const |
| bool | operator!= (const APSInt &RHS) const |
| bool | operator!= (int64_t RHS) const |
| APSInt | operator<< (unsigned Bits) const |
| APSInt & | operator<<= (unsigned Amt) |
| Left-shift assignment function. | |
| APSInt & | operator++ () |
| Prefix increment operator. | |
| APSInt & | operator-- () |
| Prefix decrement operator. | |
| APSInt | operator++ (int) |
| APSInt | operator-- (int) |
| Postfix decrement operator. | |
| APSInt | operator- () const |
| Unary negation operator. | |
| APSInt & | operator+= (const APSInt &RHS) |
| APSInt & | operator-= (const APSInt &RHS) |
| APSInt & | operator*= (const APSInt &RHS) |
| APSInt & | operator&= (const APSInt &RHS) |
| APSInt & | operator|= (const APSInt &RHS) |
| APSInt & | operator^= (const APSInt &RHS) |
| APSInt | operator& (const APSInt &RHS) const |
| APSInt | And (const APSInt &RHS) const |
| APSInt | operator| (const APSInt &RHS) const |
| APSInt | Or (const APSInt &RHS) const |
| APSInt | operator^ (const APSInt &RHS) const |
| APSInt | Xor (const APSInt &RHS) const |
| APSInt | operator* (const APSInt &RHS) const |
| APSInt | operator+ (const APSInt &RHS) const |
| APSInt | operator- (const APSInt &RHS) const |
| APSInt | operator~ () const |
| Unary bitwise complement operator. | |
| void | Profile (FoldingSetNodeID &ID) const |
Static Public Member Functions | |
| static APSInt | getMaxValue (uint32_t numBits, bool Unsigned) |
| static APSInt | getMinValue (uint32_t numBits, bool Unsigned) |
| static bool | isSameValue (const APSInt &I1, const APSInt &I2) |
| Determine if two APSInts have the same value, zero- or sign-extending as needed. | |
| llvm::APSInt::APSInt | ( | ) | [inline, explicit] |
Default constructor that creates an uninitialized APInt.
Definition at line 26 of file APSInt.h.
Referenced by extend(), extOrTrunc(), getMaxValue(), getMinValue(), isSameValue(), operator%(), operator&(), operator*(), operator+(), operator++(), operator-(), operator--(), operator/(), operator<<(), operator==(), operator>>(), operator^(), operator|(), operator~(), and trunc().
Definition at line 215 of file APSInt.h.
References operator&().
| APSInt llvm::APSInt::extend | ( | uint32_t | width | ) | const [inline] |
Definition at line 75 of file APSInt.h.
References APSInt(), llvm::APInt::sext(), and llvm::APInt::zext().
Referenced by isSameValue().
| APSInt llvm::APSInt::extOrTrunc | ( | uint32_t | width | ) | const [inline] |
Definition at line 82 of file APSInt.h.
References APSInt(), llvm::APInt::sextOrTrunc(), and llvm::APInt::zextOrTrunc().
getMaxValue - Return the APSInt representing the maximum integer value with the given bit width and signedness.
Definition at line 254 of file APSInt.h.
References APSInt(), llvm::APInt::getMaxValue(), and llvm::APInt::getSignedMaxValue().
getMinValue - Return the APSInt representing the minimum integer value with the given bit width and signedness.
Definition at line 261 of file APSInt.h.
References APSInt(), llvm::APInt::getMinValue(), and llvm::APInt::getSignedMinValue().
Determine if two APSInts have the same value, zero- or sign-extending as needed.
Definition at line 268 of file APSInt.h.
References APSInt(), extend(), llvm::APInt::getBitWidth(), llvm::APInt::isNegative(), and isSigned().
Referenced by operator==().
| bool llvm::APSInt::isSigned | ( | ) | const [inline] |
Definition at line 55 of file APSInt.h.
Referenced by llvm::APFloat::convertToInteger(), isSameValue(), llvm::operator<<(), and toString().
| bool llvm::APSInt::operator!= | ( | int64_t | RHS | ) | const [inline] |
Definition at line 105 of file APSInt.h.
References APSInt(), llvm::APInt::srem(), and llvm::APInt::urem().
Definition at line 89 of file APSInt.h.
References llvm::APInt::srem(), and llvm::APInt::urem().
| APSInt& llvm::APSInt::operator++ | ( | ) | [inline] |
Prefix increment operator.
Prefix increment operator. Increments the APInt by one.
Reimplemented from llvm::APInt.
| APSInt llvm::APSInt::operator++ | ( | int | ) | [inline] |
| APSInt llvm::APSInt::operator- | ( | ) | const [inline] |
Unary negation operator.
Negates *this using two's complement logic.
Reimplemented from llvm::APInt.
Definition at line 177 of file APSInt.h.
References APSInt().
| APSInt& llvm::APSInt::operator-- | ( | ) | [inline] |
Prefix decrement operator.
Prefix decrement operator. Decrements the APInt by one.
Reimplemented from llvm::APInt.
| APSInt llvm::APSInt::operator-- | ( | int | ) | [inline] |
Postfix decrement operator.
Reimplemented from llvm::APInt.
Definition at line 174 of file APSInt.h.
References APSInt().
Definition at line 109 of file APSInt.h.
References APSInt(), llvm::APInt::sdiv(), and llvm::APInt::udiv().
Definition at line 97 of file APSInt.h.
References llvm::APInt::sdiv(), and llvm::APInt::udiv().
Definition at line 122 of file APSInt.h.
References llvm::APInt::slt(), and llvm::APInt::ult().
Left-shift assignment function.
Shifts *this left by shiftAmt and assigns the result to *this.
Reimplemented from llvm::APInt.
Definition at line 130 of file APSInt.h.
References llvm::APInt::sle(), and llvm::APInt::ule().
Definition at line 36 of file APSInt.h.
Referenced by operator=().
| APSInt& llvm::APSInt::operator= | ( | uint64_t | RHS | ) | [inline] |
Assignment operator.
The RHS value is assigned to *this. If the significant bits in RHS exceed the bit width, the excess bits are truncated. If the bit width is larger than 64, the value is zero filled in the unspecified high order bits.
Reimplemented from llvm::APInt.
Definition at line 48 of file APSInt.h.
References operator=().
Definition at line 138 of file APSInt.h.
References llvm::APInt::eq().
| bool llvm::APSInt::operator== | ( | int64_t | RHS | ) | const [inline] |
Definition at line 142 of file APSInt.h.
References llvm::APInt::APInt(), APSInt(), and isSameValue().
Definition at line 126 of file APSInt.h.
References llvm::APInt::sgt(), and llvm::APInt::ugt().
Definition at line 134 of file APSInt.h.
References llvm::APInt::sge(), and llvm::APInt::uge().
Definition at line 114 of file APSInt.h.
References APSInt(), llvm::APInt::ashr(), and llvm::APInt::lshr().
| APSInt llvm::APSInt::operator~ | ( | ) | const [inline] |
Definition at line 223 of file APSInt.h.
References operator|().
| void APSInt::Profile | ( | FoldingSetNodeID & | ID | ) | const |
Profile - Used to insert APSInt objects, or objects that contain APSInt objects, into FoldingSets.
Reimplemented from llvm::APInt.
Definition at line 20 of file APSInt.cpp.
References llvm::FoldingSetNodeID::AddInteger().
| void llvm::APSInt::toString | ( | SmallVectorImpl< char > & | Str, |
| unsigned | Radix = 10 |
||
| ) | const [inline] |
toString - Append this APSInt to the specified SmallString.
Definition at line 61 of file APSInt.h.
References isSigned().
Referenced by toString().
| std::string llvm::APSInt::toString | ( | unsigned | Radix | ) | const [inline] |
toString - Converts an APInt to a std::string. This is an inefficient method, your should prefer passing in a SmallString instead.
Definition at line 66 of file APSInt.h.
References isSigned(), and toString().
| APSInt llvm::APSInt::trunc | ( | uint32_t | width | ) | const [inline] |
Definition at line 71 of file APSInt.h.
References APSInt(), and llvm::APInt::trunc().
Definition at line 232 of file APSInt.h.
References operator^().