From e444a960e992bc5a55142ac7f3267a08fc6ce0f5 Mon Sep 17 00:00:00 2001 From: Szabolcs Nagy Date: Thu, 15 Aug 2013 20:41:57 +0000 Subject: [PATCH] math: fix long double fpclassify tests for ldbl==dbl archs --- src/math/fpclassify.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/math/fpclassify.c b/src/math/fpclassify.c index 8a43cd6..bc77d8c 100644 --- a/src/math/fpclassify.c +++ b/src/math/fpclassify.c @@ -51,10 +51,17 @@ static struct { T(-0.0/0.0, FP_NAN) T(1/0.0, FP_INFINITE) T(-1/0.0, FP_INFINITE) +#if LDBL_MAX_EXP==16384 T(0x1.ffffp16383L, FP_NORMAL) T(-0x1.ffffp16383L, FP_NORMAL) T(0x1p-16383L, FP_SUBNORMAL) T(-0x1p-16383L, FP_SUBNORMAL) +#elif LDBL_MAX_EXP==1024 + T(0x1.ffffp1023L, FP_NORMAL) + T(-0x1.ffffp1023L, FP_NORMAL) + T(0x1p-1023L, FP_SUBNORMAL) + T(-0x1p-1023L, FP_SUBNORMAL) +#endif T(0.0, FP_ZERO) T(-0.0, FP_ZERO) T(3.14, FP_NORMAL) -- 2.20.1