reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

References

include/llvm/ADT/APSInt.h
   76   bool isSigned() const { return !IsUnsigned; }
   77   bool isUnsigned() const { return IsUnsigned; }
   78   void setIsUnsigned(bool Val) { IsUnsigned = Val; }
   79   void setIsSigned(bool Val) { IsUnsigned = !Val; }
   99     return APSInt(APInt::trunc(width), IsUnsigned);
  103     if (IsUnsigned)
  104       return APSInt(zext(width), IsUnsigned);
  106       return APSInt(sext(width), IsUnsigned);
  110     if (IsUnsigned)
  111       return APSInt(zextOrTrunc(width), IsUnsigned);
  113       return APSInt(sextOrTrunc(width), IsUnsigned);
  117     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  117     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  118     if (IsUnsigned)
  125     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  125     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  126     if (IsUnsigned)
  133     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  133     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  134     return IsUnsigned ? APSInt(urem(RHS), true) : APSInt(srem(RHS), false);
  137     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  137     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  138     return IsUnsigned ? APSInt(udiv(RHS), true) : APSInt(sdiv(RHS), false);
  142     return IsUnsigned ? APSInt(lshr(Amt), true) : APSInt(ashr(Amt), false);
  145     if (IsUnsigned)
  153     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  153     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  154     return IsUnsigned ? ult(RHS) : slt(RHS);
  157     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  157     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  158     return IsUnsigned ? ugt(RHS) : sgt(RHS);
  161     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  161     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  162     return IsUnsigned ? ule(RHS) : sle(RHS);
  165     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  165     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  166     return IsUnsigned ? uge(RHS) : sge(RHS);
  169     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  169     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  199     return APSInt(static_cast<const APInt&>(*this) << Bits, IsUnsigned);
  215     return APSInt(++static_cast<APInt&>(*this), IsUnsigned);
  218     return APSInt(--static_cast<APInt&>(*this), IsUnsigned);
  221     return APSInt(-static_cast<const APInt&>(*this), IsUnsigned);
  224     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  224     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  229     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  229     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  234     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  234     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  239     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  239     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  244     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  244     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  249     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  249     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  255     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  255     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  256     return APSInt(static_cast<const APInt&>(*this) & RHS, IsUnsigned);
  260     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  260     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  261     return APSInt(static_cast<const APInt&>(*this) | RHS, IsUnsigned);
  265     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  265     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  266     return APSInt(static_cast<const APInt&>(*this) ^ RHS, IsUnsigned);
  270     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  270     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  271     return APSInt(static_cast<const APInt&>(*this) * RHS, IsUnsigned);
  274     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  274     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  275     return APSInt(static_cast<const APInt&>(*this) + RHS, IsUnsigned);
  278     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  278     assert(IsUnsigned == RHS.IsUnsigned && "Signedness mismatch!");
  279     return APSInt(static_cast<const APInt&>(*this) - RHS, IsUnsigned);
  282     return APSInt(~static_cast<const APInt&>(*this), IsUnsigned);
  308       return I1.IsUnsigned ? I1.compare(I2) : I1.compareSigned(I2);
lib/Support/APSInt.cpp
   40   ID.AddInteger((unsigned) (IsUnsigned ? 1 : 0));