[gcc(refs/users/ibuclaw/heads/darwin)] D, Math, IBM128 : Placeholder values for constants.

Iain Buclaw ibuclaw@gcc.gnu.org
Thu Jan 28 17:33:10 GMT 2021


https://gcc.gnu.org/g:294c800914397b6f82597ef7166b253413f946be

commit 294c800914397b6f82597ef7166b253413f946be
Author: Iain Sandoe <iain@sandoe.co.uk>
Date:   Fri Dec 11 00:57:30 2020 +0000

    D, Math, IBM128 : Placeholder values for constants.
    
    These need to be checked and updated.

Diff:
---
 libphobos/src/std/internal/math/gammafunction.d | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/libphobos/src/std/internal/math/gammafunction.d b/libphobos/src/std/internal/math/gammafunction.d
index c9677c72463..981154e1ad3 100644
--- a/libphobos/src/std/internal/math/gammafunction.d
+++ b/libphobos/src/std/internal/math/gammafunction.d
@@ -257,6 +257,8 @@ else static if (floatTraits!(real).realFormat == RealFormat.ieeeExtended53)
     enum real MAXGAMMA = 1755.5483429L;
 else static if (floatTraits!(real).realFormat == RealFormat.ieeeDouble)
     enum real MAXGAMMA = 171.6243769L;
+else static if (floatTraits!(real).realFormat == RealFormat.ibmExtended)
+    enum real MAXGAMMA = 1755.5483429L;
 else
     static assert(0, "missing MAXGAMMA for other real types");
 
@@ -615,6 +617,11 @@ else static if (floatTraits!(real).realFormat == RealFormat.ieeeDouble)
     enum real MAXLOG = 0x1.62e42fefa39efp+9L;  // log(real.max)
     enum real MINLOG = -0x1.74385446d71c3p+9L; // log(real.min_normal*real.epsilon) = log(smallest denormal)
 }
+else static if (floatTraits!(real).realFormat == RealFormat.ibmExtended)
+{
+    enum real MAXLOG = 0x1.62e42fefa39ef35793c7673007e6p+9L;  // log(real.max)
+    enum real MINLOG = -0x1.6546282207802c89d24d65e96274p+9L; // log(real.min_normal*real.epsilon) = log(
+}
 else
     static assert(0, "missing MAXLOG and MINLOG for other real types");


More information about the Gcc-cvs mailing list