(Choosing a random message to reply to ...)
While looking for commercial electronics CAD software for FreeBSD, I
came across Whitely Research Inc (http://www.srware.com/) which has
this note on their site:
http://www.srware.com/linux_numerics.txt
In light of this thread, I thought
Stefan Hoffmeister wrote:
One obvious reason that the Linux approach is wrong is
that it ends up requiring the save and restore of FP
registers on context switches, which is overhead they
ate anyway, by doing TSS based context switching. The
amount of state with SSE is up to something like
Albert D. Cahalan wrote:
There are only two shared libaries in common (libc and libm) and
both are the same on FreeBSD (in /compat/linux) and Linux.
So any ideas on where the program is going wrong?
man fpsetround
That won't change a thing. Both systems round to nearest.
Look at
: On Tue, 17 Jul 2001 09:45:29 -0700, Terry Lambert wrote:
One obvious reason that the Linux approach is wrong is
that it ends up requiring the save and restore of FP
registers on context switches, which is overhead they
ate anyway, by doing TSS based context switching. The
amount of state with
[EMAIL PROTECTED] wrote:
So I have stumbled across a linux emulation bug in freebsd. Below
is the program that returns different results based on FreeBSD,
Linux or Linux emulation under FreeBSD.
[ ... ]
There are only two shared libaries in common (libc and libm) and
both are the same
Terry Lambert writes:
[EMAIL PROTECTED] wrote:
There are only two shared libaries in common (libc and libm) and
both are the same on FreeBSD (in /compat/linux) and Linux.
So any ideas on where the program is going wrong?
man fpsetround
That won't change a thing. Both systems round to
In [EMAIL PROTECTED], on 07/14/2001
at 11:09 AM, [EMAIL PROTECTED] said:
So I have stumbled across a linux emulation bug in freebsd. Below is
the program that returns different results based on FreeBSD, Linux or
Linux emulation under FreeBSD.
Running natively under FreeBSD:
x =
On Sat, Jul 14, 2001 at 11:09:22AM -0700, [EMAIL PROTECTED] wrote:
So I have stumbled across a linux emulation bug in freebsd. Below
is the program that returns different results based on FreeBSD,
Linux or Linux emulation under FreeBSD.
...
Running natively under Linux:
x = 53.278500
The correct answer to the level of accuracy you quote is:
137581029243568295877658.36934931
Both are correct to about 15 sig figs, which is about what the precision
of IEEE double precision arithmetic is supposed to be.
[EMAIL PROTECTED] wrote:
So I have stumbled across a linux emulation
On Saturday, July 14, 2001, at 11:19 AM, David O'Brien wrote:
On Sat, Jul 14, 2001 at 11:09:22AM -0700, [EMAIL PROTECTED] wrote:
So I have stumbled across a linux emulation bug in freebsd. Below
is the program that returns different results based on FreeBSD,
Linux or Linux emulation under
On Saturday, July 14, 2001, at 11:17 AM, [EMAIL PROTECTED] wrote:
In [EMAIL PROTECTED], on 07/14/2001
at 11:09 AM, [EMAIL PROTECTED] said:
So I have stumbled across a linux emulation bug in freebsd. Below is
the program that returns different results based on FreeBSD, Linux or
Linux
[EMAIL PROTECTED] wrote:
In [EMAIL PROTECTED], on 07/14/2001
at 11:09 AM, [EMAIL PROTECTED] said:
Running natively under FreeBSD:
x = 53.2785
exp(x) = 137581029243568449912832.
Running natively under Linux:
x = 53.278500
exp(x) = 137581029243568449912832.00
On Saturday, July 14, 2001, at 11:23 AM, Stephen Montgomery-Smith wrote:
The correct answer to the level of accuracy you quote is:
137581029243568295877658.36934931
Both are correct to about 15 sig figs, which is about what the precision
of IEEE double precision arithmetic is supposed to
On Saturday, July 14, 2001, at 11:19 AM, David O'Brien wrote:
On Sat, Jul 14, 2001 at 11:09:22AM -0700, [EMAIL PROTECTED] wrote:
So I have stumbled across a linux emulation bug in freebsd. Below
is the program that returns different results based on FreeBSD,
Linux or Linux emulation under
Yes, I tried out the program
#include stdio.h
#include math.h
main() {
double x,y;
int i;
x = 53.278500;
y = exp(x);
printf(%8lf\n,x);
for(i=0;isizeof(double);i++)
printf(%x ,((unsigned char*)(x))[i]);
printf(\n);
printf(%8lf\n,y);
for(i=0;isizeof(double);i++)
In [EMAIL PROTECTED], on 07/14/2001
at 01:58 PM, Stephen Montgomery-Smith [EMAIL PROTECTED]
said:
Yes, I tried out the program
#include stdio.h
#include math.h
main() {
double x,y;
int i;
x = 53.278500;
y = exp(x);
printf(%8lf\n,x);
for(i=0;isizeof(double);i++)
printf(%x
On Saturday, July 14, 2001, at 11:58 AM, Stephen Montgomery-Smith wrote:
Yes, I tried out the program
#include stdio.h
#include math.h
main() {
double x,y;
int i;
x = 53.278500;
y = exp(x);
printf(%8lf\n,x);
for(i=0;isizeof(double);i++)
printf(%x ,((unsigned
[EMAIL PROTECTED] wrote:
I also tried the same experiment with sin and gamma - then the problem
does not occur. Well except that the answer for gamma(53.278500) is
reported as 157.464664 which is way wrong.
When I tried it for x=52 they gave almost the same answer, only
seperated by
Stephen Montgomery-Smith wrote:
exp(54) = 160.331128 is way way wrong, by orders of magnitude.
Sorry - programming error - I forgot to change gamma back to exp.
--
Stephen Montgomery-Smith
[EMAIL PROTECTED]
http://www.math.missouri.edu/~stephen
To Unsubscribe: send mail to [EMAIL
Stephen Montgomery-Smith wrote:
Same for gamma(53.27850) = 157.464664.
Figured out this problem. gamma is returning the result of lgamma.
--
Stephen Montgomery-Smith
[EMAIL PROTECTED]
http://www.math.missouri.edu/~stephen
To Unsubscribe: send mail to [EMAIL PROTECTED]
with unsubscribe
So the solution to my problem was to set the __INITIAL_NPXCW__ to
0x37F. What I can think of is that the freebsd binary sets
the Control Word to this before running but the linux binary
does not (because it is assumed to already be set by the kernel
at boot time). So I would think the linux
21 matches
Mail list logo