cvs.gedasymbols.org/archives/browse.cgi   search  
Mail Archives: djgpp/1998/04/26/05:03:59

Date: Sun, 26 Apr 1998 12:02:26 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Kbwms <Kbwms AT aol DOT com>
cc: djgpp AT delorie DOT com
Subject: Re: Running paranoia in Single Mode
In-Reply-To: <7058bf47.3540f439@aol.com>
Message-ID: <Pine.SUN.3.91.980426120208.19566M-100000@is>
MIME-Version: 1.0

On Fri, 24 Apr 1998, Kbwms wrote:

> This block shows that functions of type double are used when
> running in Single mode.  To properly check the arithmetic,
> this code should be changed to reference functions of type
> float:
> 
> #ifdef Single
> #define FLOAT float
> #define FABS(x)  fabsf((x))
> #define FLOOR(x) floorf((x))
> #define LOG(x)   logf((x))
> #define POW(x,y) powf((x),(y))
> #define SQRT(x)  sqrtf((x))

These functions are not ANSI-standard, so I guess whoever ported
paranoia to C (it was originally a Fortran program, IIRC) opted to use
only what they could expect to be available.

If you indeed care that much for the quality of the float versions,
you can try making these changes yourself.  Personally, I find that
testing the float versions doesn't make much sense, since serious FP
computations usually require all variables to be doubles anyway.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019