This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] BZ#15536: Fix ulp(0x0.0p0) for 128-bit IBM long double.
- From: Andreas Schwab <schwab at linux-m68k dot org>
- To: "Carlos O'Donell" <carlos at redhat dot com>
- Cc: GNU C Library <libc-alpha at sourceware dot org>, Andreas Schwab <schwab at suse dot de>, Adhemerval Zanella <azanella at linux dot vnet dot ibm dot com>, "Joseph S. Myers" <joseph at codesourcery dot com>
- Date: Fri, 31 May 2013 10:55:52 +0200
- Subject: Re: [PATCH] BZ#15536: Fix ulp(0x0.0p0) for 128-bit IBM long double.
- References: <51A84400 dot 80005 at redhat dot com>
"Carlos O'Donell" <carlos@redhat.com> writes:
> diff --git a/math/libm-test.inc b/math/libm-test.inc
> index 7a6bf09..0b0b0d3 100644
> --- a/math/libm-test.inc
> +++ b/math/libm-test.inc
> @@ -680,7 +680,13 @@ ulp (FLOAT value)
> /* Fall through... */
> case FP_SUBNORMAL:
> /* The next closest subnormal value is a constant distance away. */
> +#if defined TEST_LDOUBLE && LDBL_MANT_DIG == 106
> + /* In 128-bit IBM long double the precision of the type degenerates
> + to double when we use subnormals. */
> + ulp = FUNC(ldexp) (1.0, 1 - (MAX_EXP + (__DBL_MANT_DIG__ - 1)));
Why do you need to use an internal identifier?
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."