Intel 8087 Math Coprocessor
|Marketed by||Intel, IBM|
|Max. CPU clock rate||4 MHz to 10 MHz|
|FSB speeds||4 MHz to 10 MHz|
|Min. feature size||3 μm|
|Instruction set||x86-16, x87|
The purpose of the 8087 was to speed up computations for floating-point arithmetic, such as addition, subtraction, multiplication, division, and square root. It also computed transcendental functions such as exponential, logarithmic or trigonometric calculations. The performance enhancements were from approximately 20% to over 500%, depending on the specific application. The 8087 could perform about 50,000 FLOPS using around 2.4 watts. Only arithmetic operations benefited from installation of an 8087; computers used only with such applications as word processing, for example, would not benefit from the extra expense (around $150 ) and power consumption of an 8087.
The sales of the 8087 received a significant boost when IBM included a coprocessor socket on the IBM PC motherboard. Development of the 8087 led to the IEEE 754-1985 standard for floating-point arithmetic. Later Intel processors (introduced after the 486DX) did not use a separate floating point coprocessor.
Design and development 
Intel had previously manufactured the 8231 Arithmetic processing unit, and the 8232 Floating Point Processor. These were designed for use with 8080 or similar processors and used an 8-bit data bus. They were interfaced to a host system either through programmed I/O or a DMA controller.
This coprocessor introduced about 60 new instructions, their assembly mnemonics all beginning with "F", to differentiate them from the 8086 integer instructions. For example, as a complement to ADD/MUL/CMP, the 8087 provided FADD/FMUL/FCOM. The binary encodings for all new instructions began with the bit pattern 11011, decimal 27, the same as the ASCII character ESC; similar instruction prefixes are also sometimes referred to as "escape codes".
Use of the coprocessor was not transparent to application programs, which had to be written to make use of the special floating point instructions. At run time, software could detect the coprocessor and use it for floating point operations; otherwise the function of the coprocessor was emulated in software.
The x87 family does not use a directly addressable register set such as the main registers of the x86 processors; instead, the x87 registers form an eight-level deep stack structure ranging from st0 to st7, where st0 is the top. The x87 instructions operate by pushing, calculating, and popping values on this stack. However, dyadic operations such as FADD, FMUL, FCMP, and so on may either implicitly use the topmost st0 and st1, or it may use st0 together with an explicit memory operand or register; the st0 register may thus be used as an accumulator (i.e. as a combined destination and left operand) and can also be exchanged with any of the eight stack registers using an instruction called FXCH stX (codes D9C8..D9CFh). This makes the x87 stack usable as seven freely addressable registers plus an accumulator. This is especially applicable on superscalar x86 processors (Pentium of 1993 and later) where these exchange instructions are optimized down to a zero clock penalty.
IEEE floating point standard 
When Intel designed the 8087, it aimed to make a standard floating-point format for future designs. An important aspect of the 8087 from a historical perspective was that it became the basis for the IEEE 754 floating-point standard. The 8087 did not implement the eventual IEEE 754 standard in all its details, as the standard was not finished until 1985, but the 80387 did. The 8087 provided two basic 32/64-bit floating-point data types and an additional extended 80-bit internal temporary format (that could also be stored in memory) to improve accuracy over large and complex calculations. Apart from this, the 8087 offered an 80-bit/18-digit packed BCD (binary coded decimal) format and 16, 32 and 64-bit integer data types.
Coprocessor interface 
The 8087 differed from subsequent Intel coprocessors in that it was directly connected to the address and data buses. The 8088/86 looked for instructions that commenced with the '11011' sequence and relinquished control to the coprocessor. The coprocessor handed control back once the sequence of coprocessor instructions ended. There was a potential crash problem if the coprocessor instruction failed to decode to one that the coprocessor understood. Intel's later coprocessors did not connect to the buses in the same way, but were handed the instructions by the main processor. This yielded an execution time penalty, but the potential crash problem was avoided because the main processor would ignore the instruction if the coprocessor refused to accept it. The 8087 was able to detect whether it was connected to a 8088 or a 8086 by monitoring the data bus during the reset cycle.
Models and second sources 
Intel 8087 coprocessors were fabricated in two variants, one with ceramic side-brazed DIP (CerDIP) and one in hermetic DIP (PDIP), and were designed to operate in the following temperature ranges:
- C, D, QC and QD prefixes: 0°C - 70°C (Commercial use).
- LC, LD, TC and TD prefixes: -40 to 85°C (Industrial use).
- MC and MD prefixes: -55°C - 125°C (Military use).
All models of the 8087 had a 40 pin DIP package and operated on 5 volts, consuming around 2.4 watts. Unlike later Intel coprocessors, the 8087 had to run at the same clock speed as the main processor. Suffixes on the part number identified the clock speed:
|Intel 8087||5 MHz|
|Intel 8087-1||10 MHz|
|Intel 8087-2||8 MHz|
|Intel 8087-3||4 MHz|
|Intel 8087-6||6 MHz|
Just as the 8088 and 8086 processors were superseded by later parts, so was the 8087 superseded. Other Intel coprocessors were the 80287, 80387, and the 80187. The 80487 was in fact a full blown i486DX chip with an extra pin. The 80486DX, Pentium, and later processors include floating-point functionality on the CPU core.
- Shvets, Gennadiy (8 October 2011). "IBM 8087 floating-point unit". CPU World. Retrieved 1 December 2011.
- Shvets, Gennadiy (8 October 2011). "AMD 8087 floating-point unit". CPU World. Retrieved 1 December 2011.
- Shvets, Gennadiy (8 October 2011). "Cyrix 8087 floating-point unit". CPU World. Retrieved 1 December 2011.
- "8087". Coprocessor Dot Info. 2007. Retrieved 1 December 2011.
- "Intel FPU". cpu-collection.de. 2011. Retrieved 1 December 2011.
- Scott Mueller, Upgrading and repairing PCs, second edition, Que Books, 1992 ISBN 0-88022-856-3, pages 395-403
- Intel Component Data Catalog 1980, Intel catalog no. C-864/280/150K/CP, pages 8-21, 8-28
- Shvets, Gennadiy (8 October 2011). "Intel 8087 family". CPU World. Retrieved 1 December 2011.
- Frolov, Sergej (10 October 2006). "USSR-made i8087 clone". CPU World. Retrieved 1 December 2011.
- Intel 80x87 math coprocessors at cpu-collection.de
- Coprocessor.info: 8087 math coprocessor history information and pictures
- Datasheet for the Intel 8087 Math Coprocessor