Subject: Re: Stupid Question
To: macbsd-general mailing list <>
From: None <>
List: macbsd-general
Date: 11/12/1994 22:12:34
[various stuff about necessity & lack of an FPU emulator deleted]

Something occured to me the other day.  It may or may not be a good
idea, but I'll throw it out there anyway...

Has anyone looked into using the SANE ROM routines in an FPU emulator?
They have the necessary precision (the only difference between SANE and
881 'double' types is two bytes of padding) and are all accessed
through a couple of traps (_PACK4 and _PACK5) using various selectors.
These traps point to ROM on my SE/30 (at least during boot - they seem
to be patched later by System 7.1).  I don't have an FPU-less machine
to experiment with, so I don't know how the picture looks on machines
that really need it.

Could we leverage any of the work Brad has done in creating the ROM ADB
driver?  I have no idea what sort of problems he has run into getting
ROM code to work, aside from the fact that he's been working on it for
some time.  I wouldn't expect the SANE routines to depend on too many
other traps, though...

I realize that there would still be a considerable amount of work to do
to get things fully functional (including implementing functions found
in the '881 but not in SANE), but not having to write some of the basic
floating point routines could make things that much easier.  

On the other hand, getting the ROM routines working reliably _could_
take longer than writing similar routines from scratch.  I can also
understand wanting to avoid using ROM code for this sort of thing -- it
could cause a whole slew of new problems.  I dunno.  Maybe we should
just compile for soft-float like cgd says.  :-)  (Probably oughta do
that even if an FPU emulator _does_ get written.  There are an awful
lot of no-fpu machines out there these days...)

- monroe
Monroe Williams