Subject: Re: accuracy of "long double"
To: Matthias Drochner <M.Drochner@fz-juelich.de>
From: Neil Booth <neil@daikokuya.co.uk>
List: port-amd64
Date: 08/31/2007 07:38:07
Matthias Drochner wrote:-
> > shouldn't it be the same as DBL_EPSILON on x86 NetBSD?
>
> Probably yes... but also LDBL_MAX is affected, and LDBL_MANT_DIG.
Actually the current definitions are correct; I rechecked the
C std and they are defined not as the minimal positive number
s.t. adding 1 is different, but in terms of the binary format.
However NetBSD does still have incorrect macros in these basic
headers, e.g. the C standard requires the following to compile,
and it fails to compile on NetBSD x86 at least:
#include <limits.h>
extern int a[USHRT_MAX * 0 - 1 < 0 ? 1: -1];
I put in a PR for this a long time ago.
Neil.