From efb5115ba29d75e1227e36da3d92dc2f5c5b6257 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Wed, 18 Mar 2020 14:48:52 -0700 Subject: [PATCH] Omit timestamp optimization invalid on 387 FPU MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit * src/timefns.c (frac_to_double): Omit optimization that is invalid on machines with excess precision (e.g., gcc x86 with 387 FPU), because it double-rounds. Found via ‘gcc -m32’ on x86-64. --- src/timefns.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/timefns.c b/src/timefns.c index 404ce4973b7..a9595b5d239 100644 --- a/src/timefns.c +++ b/src/timefns.c @@ -611,9 +611,6 @@ frac_to_double (Lisp_Object numerator, Lisp_Object denominator) ptrdiff_t ndig = mpz_sizeinbase (*n, FLT_RADIX); ptrdiff_t ddig = mpz_sizeinbase (*d, FLT_RADIX); - if (FASTER_TIMEFNS && ndig <= DBL_MANT_DIG && ddig <= DBL_MANT_DIG) - return mpz_get_d (*n) / mpz_get_d (*d); - /* Scale with SCALE when doing integer division. That is, compute (N * FLT_RADIX**SCALE) / D [or, if SCALE is negative, N / (D * FLT_RADIX**-SCALE)] as a bignum, convert the bignum to double, -- 2.39.2