Pentium FDIV bug
Encyclopedia
The Pentium FDIV bug was a bug in the Intel P5
P5 (microarchitecture)
The original Pentium microprocessor was introduced on March 22, 1993. Its microarchitecture, deemed P5, was Intel's fifth-generation and first superscalar x86 microarchitecture. As a direct extension of the 80486 architecture, it included dual integer pipelines, a faster FPU, wider data bus,...

 Pentium floating point unit
Floating point unit
A floating-point unit is a part of a computer system specially designed to carry out operations on floating point numbers. Typical operations are addition, subtraction, multiplication, division, and square root...

 (FPU). Certain floating point
Floating point
In computing, floating point describes a method of representing real numbers in a way that can support a wide range of values. Numbers are, in general, represented approximately to a fixed number of significant digits and scaled using an exponent. The base for the scaling is normally 2, 10 or 16...

 division
Division (mathematics)
right|thumb|200px|20 \div 4=5In mathematics, especially in elementary arithmetic, division is an arithmetic operation.Specifically, if c times b equals a, written:c \times b = a\,...

 operations performed with these processors would produce incorrect results. According to Intel, there were a few missing entries in the lookup table
Lookup table
In computer science, a lookup table is a data structure, usually an array or associative array, often used to replace a runtime computation with a simpler array indexing operation. The savings in terms of processing time can be significant, since retrieving a value from memory is often faster than...

 used by the digital divide operation
Division (digital)
Several algorithms exist to perform division in digital designs. These algorithms fall into two main categories: slow division and fast division. Slow division algorithms produce one digit of the final quotient per iteration. Examples of slow division include restoring, non-performing restoring,...

 algorithm.

The flaw was independently discovered and publicly disclosed in October 1994 by Professor Thomas Nicely, then at Lynchburg College
Lynchburg College
Lynchburg College is a private college in Lynchburg, Virginia, USA, related by covenant to the Christian Church with approximately 2,500 undergraduate and graduate students. The Princeton Review lists it as one of the 368 best colleges in the nation...

, Virginia
Virginia
The Commonwealth of Virginia , is a U.S. state on the Atlantic Coast of the Southern United States. Virginia is nicknamed the "Old Dominion" and sometimes the "Mother of Presidents" after the eight U.S. presidents born there...

, USA.

Although encountering the flaw was extremely rare in practice (Byte
Byte (magazine)
BYTE magazine was a microcomputer magazine, influential in the late 1970s and throughout the 1980s because of its wide-ranging editorial coverage...

magazine estimated that 1 in 9 billion floating point divides with random parameters would produce inaccurate results), both the flaw and Intel's initial handling of the matter were heavily criticized. Intel ultimately recalled the defective processors.

Chronology

Professor Thomas Nicely, then a professor of mathematics at Lynchburg College, had written code to enumerate primes, twin primes, prime triplet
Prime triplet
In mathematics, a prime triplet is a set of three prime numbers of the form or...

s, and prime quadruplets. Nicely noticed some inconsistencies in the calculations on June 13, 1994 shortly after adding a Pentium system to his group of computers, but was unable to eliminate other factors (such as programming errors, motherboard
Motherboard
In personal computers, a motherboard is the central printed circuit board in many modern computers and holds many of the crucial components of the system, providing connectors for other peripherals. The motherboard is sometimes alternatively known as the mainboard, system board, or, on Apple...

 chipsets, etc.) until October 19, 1994. On October 24, 1994 he reported the issue to Intel. According to Nicely, his contact person at Intel would later admit that Intel had been aware of the problem since May 1994, when the flaw had been discovered when testing the FPU for its new P6
P6 (microarchitecture)
The P6 microarchitecture is the sixth generation Intel x86 microarchitecture, implemented by the Pentium Pro microprocessor that was introduced in November 1995. It is sometimes referred to as i686. It was succeeded by the NetBurst microarchitecture in 2000, but eventually revived in the Pentium M...

 core, first used in the Pentium Pro
Pentium Pro
The Pentium Pro is a sixth-generation x86 microprocessor developed and manufactured by Intel introduced in November 1, 1995 . It introduced the P6 microarchitecture and was originally intended to replace the original Pentium in a full range of applications...

.

On October 30, 1994, Nicely sent an email describing the error he had discovered in the Pentium floating point unit to various contacts, requesting reports of testing for the flaw on 486-DX4s
Intel 80486DX4
The IntelDX4 is a clock-tripled i486 microprocessor with 16 kB L1 cache. Intel named it DX4 as a consequence of litigation with AMD over trademarks...

, Pentiums and Pentium clones
Pentium compatible processor
A Pentium compatible processor is a 32-bit processor computer chip which supports the instructions in the IA-32 instruction set that were implemented by the Intel P5 Pentium processor family...

.

This flaw in the Pentium FPU was quickly verified by other people around the Internet
Internet
The Internet is a global system of interconnected computer networks that use the standard Internet protocol suite to serve billions of users worldwide...

, and became known as the Pentium FDIV bug (FDIV is the x86 assembly language instruction
X86 instruction listings
The x86 instruction set has been extended several times, introducing wider registers and datatypes and/or new functionality.-x86 integer instructions:...

 for floating-point division). One example was found where the division result returned by the Pentium was off by about 61 parts per million.

The story first appeared in the press on November 7, 1994, in an article in Electronic Engineering Times, "Intel fixes a Pentium FPU glitch" by Alexander Wolfe.

The story was subsequently picked up by CNN in a segment which aired on November 21, 1994. This brought it into widespread public prominence.

Publicly, Intel acknowledged the floating point flaw but claimed that it was not serious and would not affect most users. Intel offered to replace processors to users who could prove that they were affected. However, although most independent estimates found the bug to be of little importance and would have negligible effect on most users, it caused a great public outcry. Companies like IBM (whose IBM 5x86C microprocessor
Microprocessor
A microprocessor incorporates the functions of a computer's central processing unit on a single integrated circuit, or at most a few integrated circuits. It is a multipurpose, programmable device that accepts digital data as input, processes it according to instructions stored in its memory, and...

 competed at that time with the Intel Pentium line) joined the condemnation.

On December 20, 1994 Intel offered to replace all flawed Pentium processors on the basis of request, in response to mounting public pressure. Although it turned out that only a small fraction of Pentium owners bothered to get their chips replaced, the financial impact on the company was significant. Intel announced on January 17, 1995, a pre-tax charge of $475 million against earnings, ostensibly the total cost associated with replacement of the flawed processors. Some of the defective chips were later turned into key rings by Intel.

A 1995 article in Science
Science (journal)
Science is the academic journal of the American Association for the Advancement of Science and is one of the world's top scientific journals....

describes the value of number theory problems in discovering computer bugs and gives the mathematical background and history of Brun's constant, the problem Nicely was working on when he discovered the bug.

Affected models

This problem occurred only on some models of the original Pentium processor. Any Pentium family processor with a clock speed of at least 120 MHz is new enough not to have this bug.

On affected models, the Intel Processor Frequency ID Utility checks for the presence of this bug.

The ten affected processors are listed below. The 39 S-spec of those processors are not listed in the Intel processor specification finder web page.
Pentium P5 800 nm 5V
Family Model Stepping Manufacturing Stepping Clock rate FSB
Front side bus
A front-side bus is a computer communication interface often used in computers during the 1990s and 2000s.It typically carries data between the central processing unit and a memory controller hub, known as the northbridge....

 speed
S-spec
5 1 3 B1 60 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0352
5 1 3 B1 60 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0412
5 1 3 B1 60 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX753
5 1 3 B1 66 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz Q0353
5 1 3 B1 66 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz Q0413
5 1 3 B1 66 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz SX754
5 1 5 C1 60 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0466
5 1 5 C1 60 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX835
5 1 5 C1 60 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SZ949
5 1 5 C1 66 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz Q0467
5 1 5 C1 66 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz SX837
5 1 5 C1 66 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz SZ950

Pentium P54C 600 nm 3.3V
Family Model Stepping Manufacturing Stepping Clock rate FSB
Front side bus
A front-side bus is a computer communication interface often used in computers during the 1990s and 2000s.It typically carries data between the central processing unit and a memory controller hub, known as the northbridge....

 speed
S-spec
5 2 1 B1 75 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
50 MHz Q0601
5 2 1 B1 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0542
5 2 1 B1 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0613
5 2 1 B1 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0543
5 2 1 B1 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX879
5 2 1 B1 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX885
5 2 1 B1 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX909
5 2 1 B1 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX874
5 2 1 B1 100 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz Q0563
5 2 1 B1 100 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz Q0587
5 2 1 B1 100 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz Q0614
5 2 1 B1 100 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz SX886
5 2 1 B1 100 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz SX910
5 2 2 B3 75 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
50 MHz Q0606
5 2 2 B3 75 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
50 MHz SX951
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0628
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0611
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz Q0612
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX923
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX922
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX921
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX942
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX943
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SX944
5 2 2 B3 90 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
60 MHz SZ951
5 2 2 B3 100 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz Q0677
5 2 2 B3 100 MHz
Hertz
The hertz is the SI unit of frequency defined as the number of cycles per second of a periodic phenomenon. One of its most common uses is the description of the sine wave, particularly those used in radio and audio applications....

 
66 MHz SX960


The presence of the bug can be checked manually by performing the following calculation in any application that uses native floating point numbers, including the Windows Calculator or Microsoft Excel
Microsoft Excel
Microsoft Excel is a proprietary commercial spreadsheet application written and distributed by Microsoft for Microsoft Windows and Mac OS X. It features calculation, graphing tools, pivot tables, and a macro programming language called Visual Basic for Applications...

 in Windows 95
Windows 95
Windows 95 is a consumer-oriented graphical user interface-based operating system. It was released on August 24, 1995 by Microsoft, and was a significant progression from the company's previous Windows products...

/98
Windows 98
Windows 98 is a graphical operating system by Microsoft. It is the second major release in the Windows 9x line of operating systems. It was released to manufacturing on 15 May 1998 and to retail on 25 June 1998. Windows 98 is the successor to Windows 95. Like its predecessor, it is a hybrid...

.

The correct value is


However, the value returned by the flawed Pentium would be incorrect beyond four significant digits:

See also

  • Pentium F00F bug
  • Anomaly in software
    Anomaly in software
    In software testing, a software anomaly is anything that differs from expectation. This expectation can result from many things like from a document or from a person's view or experiences In software testing, a software anomaly is anything that differs from expectation. This expectation can...

  • MOS Technology 6502 bugs and quirks
  • Accuracy problems in floating point operations

External links

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK