LLVM
8.0.1
|
#include "llvm/ADT/APFloat.h"
Friends | |
int | ilogb (const DoubleAPFloat &Arg) |
DoubleAPFloat | scalbn (DoubleAPFloat X, int Exp, roundingMode) |
DoubleAPFloat | frexp (const DoubleAPFloat &X, int &Exp, roundingMode) |
hash_code | hash_value (const DoubleAPFloat &Arg) |
Additional Inherited Members | |
Public Types inherited from llvm::APFloatBase | |
enum | cmpResult { cmpLessThan, cmpEqual, cmpGreaterThan, cmpUnordered } |
IEEE-754R 5.11: Floating Point Comparison Relations. More... | |
enum | roundingMode { rmNearestTiesToEven, rmTowardPositive, rmTowardNegative, rmTowardZero, rmNearestTiesToAway } |
IEEE-754R 4.3: Rounding-direction attributes. More... | |
enum | opStatus { opOK = 0x00, opInvalidOp = 0x01, opDivByZero = 0x02, opOverflow = 0x04, opUnderflow = 0x08, opInexact = 0x10 } |
IEEE-754R 7: Default exception handling. More... | |
enum | fltCategory { fcInfinity, fcNaN, fcNormal, fcZero } |
Category of internally-represented number. More... | |
enum | uninitializedTag { uninitialized } |
Convenience enum used to construct an uninitialized APFloat. More... | |
enum | IlogbErrorKinds { IEK_Zero = INT_MIN + 1, IEK_NaN = INT_MIN, IEK_Inf = INT_MAX } |
Enumeration of ilogb error results. More... | |
typedef APInt::WordType | integerPart |
typedef signed short | ExponentType |
A signed type to represent a floating point numbers unbiased exponent. More... | |
Static Public Member Functions inherited from llvm::APFloatBase | |
static unsigned int | semanticsPrecision (const fltSemantics &) |
static ExponentType | semanticsMinExponent (const fltSemantics &) |
static ExponentType | semanticsMaxExponent (const fltSemantics &) |
static unsigned int | semanticsSizeInBits (const fltSemantics &) |
static unsigned | getSizeInBits (const fltSemantics &Sem) |
Returns the size of the floating point number (in bits) in the given semantics. More... | |
static const fltSemantics & | IEEEhalf () LLVM_READNONE |
static const fltSemantics & | IEEEsingle () LLVM_READNONE |
static const fltSemantics & | IEEEdouble () LLVM_READNONE |
static const fltSemantics & | IEEEquad () LLVM_READNONE |
static const fltSemantics & | PPCDoubleDouble () LLVM_READNONE |
static const fltSemantics & | x87DoubleExtended () LLVM_READNONE |
static const fltSemantics & | Bogus () LLVM_READNONE |
A Pseudo fltsemantic used to construct APFloats that cannot conflict with anything real. More... | |
Static Public Attributes inherited from llvm::APFloatBase | |
static const unsigned | integerPartWidth = APInt::APINT_BITS_PER_WORD |
llvm::detail::DoubleAPFloat::DoubleAPFloat | ( | const fltSemantics & | S | ) |
Definition at line 3847 of file APFloat.cpp.
References llvm::lltok::APFloat, and assert().
Referenced by convertFromAPInt(), convertFromSignExtendedInteger(), convertFromString(), convertFromZeroExtendedInteger(), divide(), llvm::detail::frexp(), fusedMultiplyAdd(), mod(), next(), operator=(), remainder(), roundToIntegral(), and llvm::detail::scalbn().
llvm::detail::DoubleAPFloat::DoubleAPFloat | ( | const fltSemantics & | S, |
uninitializedTag | |||
) |
Definition at line 3853 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), and llvm::APFloatBase::uninitialized.
llvm::detail::DoubleAPFloat::DoubleAPFloat | ( | const fltSemantics & | S, |
integerPart | I | ||
) |
Definition at line 3860 of file APFloat.cpp.
References llvm::lltok::APFloat, and assert().
llvm::detail::DoubleAPFloat::DoubleAPFloat | ( | const fltSemantics & | S, |
const APInt & | I | ||
) |
Definition at line 3866 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), and llvm::APInt::getRawData().
llvm::detail::DoubleAPFloat::DoubleAPFloat | ( | const fltSemantics & | S, |
APFloat && | First, | ||
APFloat && | Second | ||
) |
Definition at line 3874 of file APFloat.cpp.
References assert().
llvm::detail::DoubleAPFloat::DoubleAPFloat | ( | const DoubleAPFloat & | RHS | ) |
Definition at line 3883 of file APFloat.cpp.
References llvm::lltok::APFloat, and assert().
llvm::detail::DoubleAPFloat::DoubleAPFloat | ( | DoubleAPFloat && | RHS | ) |
Definition at line 3891 of file APFloat.cpp.
References assert(), and llvm::semBogus.
APFloat::opStatus llvm::detail::DoubleAPFloat::add | ( | const DoubleAPFloat & | RHS, |
roundingMode | RM | ||
) |
Definition at line 4036 of file APFloat.cpp.
Referenced by subtract().
APInt llvm::detail::DoubleAPFloat::bitcastToAPInt | ( | ) | const |
Definition at line 4271 of file APFloat.cpp.
References assert(), and llvm::Data.
Referenced by convertToHexString(), convertToInteger(), divide(), fusedMultiplyAdd(), getExactInverse(), mod(), next(), remainder(), roundToIntegral(), and toString().
bool llvm::detail::DoubleAPFloat::bitwiseIsEqual | ( | const DoubleAPFloat & | RHS | ) | const |
Definition at line 4260 of file APFloat.cpp.
void llvm::detail::DoubleAPFloat::changeSign | ( | ) |
Definition at line 4183 of file APFloat.cpp.
Referenced by makeLargest(), and subtract().
APFloat::cmpResult llvm::detail::DoubleAPFloat::compare | ( | const DoubleAPFloat & | RHS | ) | const |
Definition at line 4252 of file APFloat.cpp.
References llvm::APFloatBase::cmpEqual.
Referenced by isLargest(), and isSmallest().
APFloat::cmpResult llvm::detail::DoubleAPFloat::compareAbsoluteValue | ( | const DoubleAPFloat & | RHS | ) | const |
Definition at line 4189 of file APFloat.cpp.
References llvm::APFloatBase::cmpEqual, llvm::APFloatBase::cmpGreaterThan, and llvm::APFloatBase::cmpLessThan.
APFloat::opStatus llvm::detail::DoubleAPFloat::convertFromAPInt | ( | const APInt & | Input, |
bool | IsSigned, | ||
roundingMode | RM | ||
) |
Definition at line 4306 of file APFloat.cpp.
References assert(), llvm::APFloat::bitcastToAPInt(), llvm::APFloat::convertFromAPInt(), DoubleAPFloat(), and llvm::MipsISD::Ret.
APFloat::opStatus llvm::detail::DoubleAPFloat::convertFromSignExtendedInteger | ( | const integerPart * | Input, |
unsigned int | InputSize, | ||
bool | IsSigned, | ||
roundingMode | RM | ||
) |
Definition at line 4317 of file APFloat.cpp.
References assert(), llvm::APFloat::bitcastToAPInt(), llvm::APFloat::convertFromSignExtendedInteger(), DoubleAPFloat(), and llvm::MipsISD::Ret.
APFloat::opStatus llvm::detail::DoubleAPFloat::convertFromString | ( | StringRef | , |
roundingMode | |||
) |
Definition at line 4280 of file APFloat.cpp.
References assert(), llvm::APFloat::bitcastToAPInt(), llvm::APFloat::convertFromString(), DoubleAPFloat(), and llvm::MipsISD::Ret.
Referenced by llvm::APFloat::convertFromString().
APFloat::opStatus llvm::detail::DoubleAPFloat::convertFromZeroExtendedInteger | ( | const integerPart * | Input, |
unsigned int | InputSize, | ||
bool | IsSigned, | ||
roundingMode | RM | ||
) |
Definition at line 4328 of file APFloat.cpp.
References assert(), llvm::APFloat::bitcastToAPInt(), llvm::APFloat::convertFromZeroExtendedInteger(), DoubleAPFloat(), and llvm::MipsISD::Ret.
unsigned int llvm::detail::DoubleAPFloat::convertToHexString | ( | char * | DST, |
unsigned int | HexDigits, | ||
bool | UpperCase, | ||
roundingMode | RM | ||
) | const |
Definition at line 4338 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), and bitcastToAPInt().
APFloat::opStatus llvm::detail::DoubleAPFloat::convertToInteger | ( | MutableArrayRef< integerPart > | Input, |
unsigned int | Width, | ||
bool | IsSigned, | ||
roundingMode | RM, | ||
bool * | IsExact | ||
) | const |
Definition at line 4298 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), and bitcastToAPInt().
APFloat::opStatus llvm::detail::DoubleAPFloat::divide | ( | const DoubleAPFloat & | RHS, |
roundingMode | RM | ||
) |
Definition at line 4135 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), bitcastToAPInt(), llvm::APFloat::bitcastToAPInt(), llvm::APFloat::divide(), DoubleAPFloat(), and llvm::MipsISD::Ret.
APFloat::opStatus llvm::detail::DoubleAPFloat::fusedMultiplyAdd | ( | const DoubleAPFloat & | Multiplicand, |
const DoubleAPFloat & | Addend, | ||
roundingMode | RM | ||
) |
Definition at line 4163 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), bitcastToAPInt(), llvm::APFloat::bitcastToAPInt(), DoubleAPFloat(), llvm::APFloat::fusedMultiplyAdd(), and llvm::MipsISD::Ret.
APFloat::fltCategory llvm::detail::DoubleAPFloat::getCategory | ( | ) | const |
Definition at line 4209 of file APFloat.cpp.
Referenced by llvm::detail::frexp(), isDenormal(), isLargest(), isSmallest(), multiply(), and operator=().
Definition at line 4384 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), bitcastToAPInt(), llvm::APFloat::bitcastToAPInt(), llvm::APFloat::getExactInverse(), and llvm::MipsISD::Ret.
|
inline |
Definition at line 609 of file APFloat.h.
References llvm::ARM_AM::add, llvm::ScaledNumbers::compare(), llvm::frexp(), llvm::hash_value(), llvm::detail::ilogb(), remainder, llvm::scalbn(), and llvm::toString().
bool llvm::detail::DoubleAPFloat::isDenormal | ( | ) | const |
Definition at line 4347 of file APFloat.cpp.
References llvm::APFloatBase::cmpEqual, llvm::APFloatBase::fcNormal, and getCategory().
bool llvm::detail::DoubleAPFloat::isInteger | ( | ) | const |
Definition at line 4370 of file APFloat.cpp.
References assert().
bool llvm::detail::DoubleAPFloat::isLargest | ( | ) | const |
Definition at line 4362 of file APFloat.cpp.
References llvm::APFloatBase::cmpEqual, compare(), llvm::APFloatBase::fcNormal, getCategory(), isNegative(), and makeLargest().
bool llvm::detail::DoubleAPFloat::isNegative | ( | ) | const |
Definition at line 4213 of file APFloat.cpp.
Referenced by isLargest(), isSmallest(), and operator=().
bool llvm::detail::DoubleAPFloat::isSmallest | ( | ) | const |
Definition at line 4354 of file APFloat.cpp.
References llvm::APFloatBase::cmpEqual, compare(), llvm::APFloatBase::fcNormal, getCategory(), isNegative(), and makeSmallest().
void llvm::detail::DoubleAPFloat::makeInf | ( | bool | Neg | ) |
Definition at line 4215 of file APFloat.cpp.
void llvm::detail::DoubleAPFloat::makeLargest | ( | bool | Neg | ) |
Definition at line 4225 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), and changeSign().
Referenced by isLargest().
Definition at line 4247 of file APFloat.cpp.
Referenced by multiply(), and operator=().
void llvm::detail::DoubleAPFloat::makeSmallest | ( | bool | Neg | ) |
void llvm::detail::DoubleAPFloat::makeSmallestNormalized | ( | bool | Neg | ) |
Definition at line 4239 of file APFloat.cpp.
References llvm::lltok::APFloat, and assert().
void llvm::detail::DoubleAPFloat::makeZero | ( | bool | Neg | ) |
Definition at line 4220 of file APFloat.cpp.
APFloat::opStatus llvm::detail::DoubleAPFloat::mod | ( | const DoubleAPFloat & | RHS | ) |
Definition at line 4154 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), bitcastToAPInt(), llvm::APFloat::bitcastToAPInt(), DoubleAPFloat(), llvm::APFloat::mod(), and llvm::MipsISD::Ret.
APFloat::opStatus llvm::detail::DoubleAPFloat::multiply | ( | const DoubleAPFloat & | RHS, |
roundingMode | RM | ||
) |
Definition at line 4049 of file APFloat.cpp.
References llvm::APFloat::add(), assert(), B, C, llvm::APFloat::changeSign(), D, llvm::APFloatBase::fcInfinity, llvm::APFloatBase::fcNaN, llvm::APFloatBase::fcNormal, llvm::APFloatBase::fcZero, llvm::APFloat::fusedMultiplyAdd(), getCategory(), llvm::APFloat::isFinite(), llvm::APFloat::isFiniteNonZero(), makeNaN(), llvm::APFloat::multiply(), llvm::APFloatBase::opOK, llvm::APFloat::subtract(), T, and llvm::RISCVFenceField::W.
|
inline |
APFloat::opStatus llvm::detail::DoubleAPFloat::next | ( | bool | nextDown | ) |
Definition at line 4289 of file APFloat.cpp.
References assert(), bitcastToAPInt(), llvm::APFloat::bitcastToAPInt(), DoubleAPFloat(), llvm::APFloat::next(), and llvm::MipsISD::Ret.
DoubleAPFloat & llvm::detail::DoubleAPFloat::operator= | ( | const DoubleAPFloat & | RHS | ) |
Definition at line 3897 of file APFloat.cpp.
References aa, llvm::APFloat::add(), assert(), C, llvm::APFloat::changeSign(), llvm::APFloatBase::cmpGreaterThan, DoubleAPFloat(), llvm::APFloatBase::fcInfinity, llvm::APFloatBase::fcNaN, llvm::APFloatBase::fcNormal, llvm::APFloatBase::fcZero, getCategory(), llvm::APFloat::isFinite(), llvm::APFloat::isInfinity(), isNegative(), makeNaN(), llvm::APFloatBase::opInvalidOp, llvm::APFloatBase::opOK, llvm::NVPTX::PTXCvtMode::RM, llvm::semIEEEdouble, and llvm::APFloat::subtract().
|
inline |
APFloat::opStatus llvm::detail::DoubleAPFloat::remainder | ( | const DoubleAPFloat & | RHS | ) |
Definition at line 4145 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), bitcastToAPInt(), llvm::APFloat::bitcastToAPInt(), DoubleAPFloat(), llvm::APFloat::remainder(), and llvm::MipsISD::Ret.
APFloat::opStatus llvm::detail::DoubleAPFloat::roundToIntegral | ( | roundingMode | RM | ) |
Definition at line 4175 of file APFloat.cpp.
References assert(), bitcastToAPInt(), llvm::APFloat::bitcastToAPInt(), DoubleAPFloat(), llvm::MipsISD::Ret, and llvm::APFloat::roundToIntegral().
APFloat::opStatus llvm::detail::DoubleAPFloat::subtract | ( | const DoubleAPFloat & | RHS, |
roundingMode | RM | ||
) |
Definition at line 4041 of file APFloat.cpp.
References add(), changeSign(), and llvm::MipsISD::Ret.
void llvm::detail::DoubleAPFloat::toString | ( | SmallVectorImpl< char > & | Str, |
unsigned | FormatPrecision, | ||
unsigned | FormatMaxPadding, | ||
bool | TruncateZero = true |
||
) | const |
Definition at line 4375 of file APFloat.cpp.
References llvm::lltok::APFloat, assert(), and bitcastToAPInt().
|
friend |
Referenced by llvm::detail::frexp().
|
friend |
Definition at line 4265 of file APFloat.cpp.
Referenced by llvm::detail::hash_value(), and llvm::hash_value().
|
friend |
|
friend |
Referenced by llvm::detail::frexp(), and llvm::detail::scalbn().