[comp.sys.next] 040 Floating Point bugs?

bchen@nntp-server.caltech.edu.UUCP (Bing-Qing Chen) (12/20/90)

The following small program will crash 040 NeXT while it will run fine on
030 NeXT runing 2.0 Software. The crash is so bad that both 
COMMAND-` and COMMAND-COMMAND-` keys will not work. I suspect that is a
bug in 040 rather than in OS software. I also noted that even though
040 can do simple floating point operations much faster than 030, it
can't do most of the floating point operations not implemented in
hardware faster than 030. The following is the timing infomation for
doing 1000000 Sin:
030: 19.8u 0.3s 0:20 98% 0+0k 1+0io 0pf+0w
040: 0.8u 28.6s 0:30 98% 0+0k 10+0io 0pf+0w
Note that 040 spent most of the time in system time. Is this a bug in NeXT OS
or 040 just can't do these operations faster than 030? 

---The follwing program will crash 040 NeXT, compile it with cc -O -----
main()
{
  double x,y;
  int i;

  x=2;
  y=2;
  for (i=0; i< 5000000; i++ )
    x /= y;
  printf("%g\n",x);
}

--------------
Bing Chen
NeXT mail: bchen@pooh.caltech.edu