diff options
author | Evan Cheng <evan.cheng@apple.com> | 2009-10-28 01:08:17 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2009-10-28 01:08:17 +0000 |
commit | deab9dee122336a6b1916a94c84e7bbc6a2e2f3f (patch) | |
tree | 86b3fd80ccd5643e2cfc3f326aa336c4684000a9 /llvm/lib/Support/APFloat.cpp | |
parent | 9c6bc1f56359ce85038f92912a88b3759a74c933 (diff) | |
download | bcm5719-llvm-deab9dee122336a6b1916a94c84e7bbc6a2e2f3f.tar.gz bcm5719-llvm-deab9dee122336a6b1916a94c84e7bbc6a2e2f3f.zip |
Remove getIEEEFloatParts and getIEEEDoubleParts. They are not needed.
llvm-svn: 85358
Diffstat (limited to 'llvm/lib/Support/APFloat.cpp')
-rw-r--r-- | llvm/lib/Support/APFloat.cpp | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/llvm/lib/Support/APFloat.cpp b/llvm/lib/Support/APFloat.cpp index d286833126f..b9b323c4242 100644 --- a/llvm/lib/Support/APFloat.cpp +++ b/llvm/lib/Support/APFloat.cpp @@ -2632,56 +2632,6 @@ APFloat::getHashValue() const } } -void APFloat::getIEEEFloatParts(bool &Sign, uint32_t &Exp, - uint32_t &Significand) const { - assert(semantics == (const llvm::fltSemantics*)&IEEEsingle && - "Float semantics are not IEEEsingle"); - assert(partCount()==1); - - if (category == fcNormal) { - Exp = exponent+127; // bias - Significand = (uint32_t)*significandParts(); - if (Exp == 1 && !(Significand & 0x800000)) - Exp = 0; // denormal - } else if (category==fcZero) { - Exp = 0; - Significand = 0; - } else if (category==fcInfinity) { - Exp = 0xff; - Significand = 0; - } else { - assert(category == fcNaN && "Unknown category!"); - Exp = 0xff; - Significand = (uint32_t)*significandParts(); - } - Sign = sign; -} - -void APFloat::getIEEEDoubleParts(bool &Sign, uint64_t &Exp, - uint64_t &Significand) const { - assert(semantics == (const llvm::fltSemantics*)&IEEEdouble && - "Float semantics are not IEEEdouble"); - assert(partCount()==1); - - if (category == fcNormal) { - Exp = exponent+1023; // bias - Significand = *significandParts(); - if (Exp == 1 && !(Significand & 0x10000000000000LL)) - Exp = 0; // denormal - } else if (category==fcZero) { - Exp = 0; - Significand = 0; - } else if (category==fcInfinity) { - Exp = 0x7ff; - Significand = 0; - } else { - assert(category == fcNaN && "Unknown category!"); - Exp = 0x7ff; - Significand = *significandParts(); - } - Sign = sign; -} - // Conversion from APFloat to/from host float/double. It may eventually be // possible to eliminate these and have everybody deal with APFloats, but that // will take a while. This approach will not easily extend to long double. |