Re: R-alpha: Machine Constants

Douglas Bates (bates@stat.wisc.edu)
Thu, 5 Dec 1996 14:46:34 -0600 (CST)


Message-Id: <m0vVkgk-000hhyC@franz.stat.wisc.edu>
Date: Thu, 5 Dec 1996 14:46:34 -0600 (CST)
From: Douglas Bates <bates@stat.wisc.edu>
To: Ross Ihaka <ihaka@stat.auckland.ac.nz>
Subject: Re: R-alpha: Machine Constants
In-Reply-To: <199612050113.OAA20609@stat13.stat.auckland.ac.nz>
 <199612050113.OAA20609@stat13.stat.auckland.ac.nz>

Setting all the local variables to be volatile seems to work fine.  I
have tried this version of machar on a Debian Linux/ELF i686 system
 % uname -a
 Linux franz 2.0.24 #1 Wed Nov 6 16:37:27 CST 1996 i686
obtaining the results
 % cc -o machar -O machar.c
 % machar
 % ./machar
 ibeta = 2
 it = 53
 irnd = 5
 negep = -53
 epsneg = 1.1102230246252e-16
 machep = -52
 eps = 2.2204460492503e-16
 ngrd = 0
 iexp = 11
 minexp = -1022
 xmin = 2.2250738585072e-308
 maxexp = 1024
 xmax = 1.7976931348623e+308
 % cc -o machar -O3 machar.c
 % ./machar
 ibeta = 2
 it = 53
 irnd = 5
 negep = -53
 epsneg = 1.1102230246252e-16
 machep = -52
 eps = 2.2204460492503e-16
 ngrd = 0
 iexp = 11
 minexp = -1022
 xmin = 2.2250738585072e-308
 maxexp = 1024
 xmax = 1.7976931348623e+308
If I comment out the "volatile" part of the declaration the results are
 % cc -o machar -O machar.c
 % ./machar
 ibeta = 2
 it = 64
 irnd = 5
 negep = -64
 epsneg = 5.4210108624275e-20
 machep = -63
 eps = 1.0842021724855e-19
 ngrd = 0
 iexp = 1
 minexp = -2
 xmin = 0.25
 maxexp = -2
 xmax = 0.5
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
r-testers mailing list -- For info or help, send "info" or "help",
To [un]subscribe, send "[un]subscribe"
(in the "body", not the subject !)  To: r-testers-request@stat.math.ethz.ch
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-