8087 Emulation on 8086 Systems

os2museum.com

66 points by ingve a day ago


wglb - a day ago

While I was at Mark Williams back in the day, the engineers wrote 8087 emulation floating point for the Mark Williams 8086 compiler. This involved some quality time with the Volume 2 of Knuth in the log division section.

watersb - 19 hours ago

> Because the 8086 had no facility for emulating an FPU (unlike the 80286 and later processors), the emulation mechanism was somewhat complex and required tight cooperation of assemblers/compilers, linkers, and run-time libraries.

The article goes into some detail on the extra effort required to implement FPU hardware emulation on a platform that did not especially support it.

Modern implementation of FPU emulation might be more straightforward.

I haven't worked with FPU emulation on microcontrollers, which is probably the most common use case these days.

xattt - a day ago

The article states that the 8087 was an expensive add-on.

Was this price point a deliberate market differentiator, or was there some special sauce within FPU that was otherwise difficult to attain?

bombcar - a day ago

The interesting thing about the 8087 is that the co-processor interface was kind of generic. In theory you could have had things beyond just an FPU, but I don't know if much was ever done using it.

dehrmann - a day ago

Fun trivia: Intel's PCI vendor ID is 8086.

anthk - 20 hours ago

https://github.com/howerj/muxleq (subleq and muxleq). Look at the EForth code on how a small FP it's implemented. Also, learn about Forth, it's dumb easy to understand.