diff options
Diffstat (limited to 'src/3rdparty/double-conversion/diy-fp.h')
-rw-r--r-- | src/3rdparty/double-conversion/diy-fp.h | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/3rdparty/double-conversion/diy-fp.h b/src/3rdparty/double-conversion/diy-fp.h index 9dcf8fbdba..2edf34674e 100644 --- a/src/3rdparty/double-conversion/diy-fp.h +++ b/src/3rdparty/double-conversion/diy-fp.h @@ -42,7 +42,7 @@ class DiyFp { static const int kSignificandSize = 64; DiyFp() : f_(0), e_(0) {} - DiyFp(uint64_t f, int e) : f_(f), e_(e) {} + DiyFp(uint64_t significand, int exponent) : f_(significand), e_(exponent) {} // this = this - other. // The exponents of both numbers must be the same and the significand of this @@ -76,22 +76,22 @@ class DiyFp { void Normalize() { ASSERT(f_ != 0); - uint64_t f = f_; - int e = e_; + uint64_t significand = f_; + int exponent = e_; // This method is mainly called for normalizing boundaries. In general // boundaries need to be shifted by 10 bits. We thus optimize for this case. const uint64_t k10MSBits = UINT64_2PART_C(0xFFC00000, 00000000); - while ((f & k10MSBits) == 0) { - f <<= 10; - e -= 10; + while ((significand & k10MSBits) == 0) { + significand <<= 10; + exponent -= 10; } - while ((f & kUint64MSB) == 0) { - f <<= 1; - e--; + while ((significand & kUint64MSB) == 0) { + significand <<= 1; + exponent--; } - f_ = f; - e_ = e; + f_ = significand; + e_ = exponent; } static DiyFp Normalize(const DiyFp& a) { |