Thursday, January 13, 2005

The 640k Legend

It does not really come as a surprise: Bill Gates' famous "640k should be enough for everyone"-statement is a canard. James Fallows (National correspondent for "The New York Review of Books") recently received the following mail from the Microsoft Chairman and Chief Software Architect...

This is one of those "quotes" that won't seem to go away.

I've explained that it's wrong when it's come up every few years, including in a newspaper column and in interviews.

There is a lot of irony to this one. Lou Eggebrecht (who really designed the IBM PC original hardware) and I wanted to convince IBM to have a 32-bit address space, but the 68000 [a Motorola-designed processing chip, eventually used in the Apple Macintosh] just wasn't ready. Lew had an early prototype but it would have delayed things at least a year.

The 8086/8088 [the Intel-designed chip used in early personal computers] architecture has a 20-bit address bus [the mechanism used by the microprocessor to access memory; each additional "bit" in the address bus doubles the amount of memory that can be used], and the instruction set [the basic set of commands that the microprocessor understands] only generates 20-bit addresses.

I and many others have said the industry "uses" an extra address bit every two years, as hardware and software become more powerful, so going from 16-bit to 20-bit was clearly not going to last us very long. The extra silicon to do 32-bit addressing is trivial, but it wasn't there. The VAX was around and all the 68000 people did was look at the VAX! 2 to the 20th is 1 megabyte (1024K), so you might ask why the difference between 640K and 1024K—where did the last 384K go?

The answer is that in that 1M of address space we had to accommodate RAM [random access memory], ROM [read-only memory], and I/O addresses [Input/Output addresses used for "peripherals" like keyboards, disk drives, and hard drives], and IBM laid it out so those other things started at 640K and used all the memory space up to 1M. If they had been a bit more careful we could have had 800K instead of 640K available.

In fact, we had 800K on the Sirius machine, which I got to have a lot of input on (designed by Chuck Peddle, who did the Commodore Pet and the 6502, too). The key problem though is not getting to use only 640K of the 1M of address space that was available. It's the 1M limit, which comes from having only 20 bits of address space, which is all that chip can handle!

So, this limit has nothing to do with any Microsoft software.

Although people talk about previous computing as 8-bit, it was 16-bit addressing in the 8080/Z80/6800/6502 [all early processing chips]. So we had only 64K of addressability.

Amazingly people like Bob Harp (Vector Graphics—remember them?) went around the industry saying we should stick with that and just use bank switching techniques. Bank switching comes up whenever an address space is at the end of its life. It's a hack where you have more physical memory than logical memory. Fortunately we got enough applications moved to the 8086/8 machines to get the industry off of 16-bit addressing, but it was clear from the start the extra 4 bits wouldn't be sufficient for long.

Now you MIGHT think that the next time around the chip guys would get it right.

But NO, instead of going from 20 bits to 32 bits, we got the 286 chip next. Intel had its A team working on the 432 (remember that? Fortune had a silly article about how it was so far ahead of everyone, but it was a dead end even though its address space was fine). The 286's address space wasn't fine. It only had 24 bits. It used segments instead of pages and the segments were limited to 24 bits.

When Intel produced the 32-bit 386 chip, IBM delayed doing a 386 machine because they had a special version of the 286 that only they could get, and they ordered way too many of them.

It's hard to remember, but companies were chicken to do a 386 machine before IBM. I went down to Compaq five times and they decided to be brave and do it. They came out with a 386 machine! So finally the PC industry had a 32-bit address space.

We have just recently passed through the 32-bit limit and are going to 64-bit. This is another complex story. Itanium is 64-bit. Meanwhile, AMD on its own has extended the x86 to 64-bit.

Even 64-bit architecture won't last forever, but it will last for quite a while since only servers and scientific stuff have run out of 32-bit space right now. In three or four years the industry will have moved over to 64-bit architecture, and it looks like it will suffice for more than a decade.

Apollo actually did 128-bit architecture really early, as did some IBM architectures. But there are tradeoffs that made those not ever become mainstream.

A long answer to just say "no." I don't want anyone thinking that the address limits of the PC had something to do with software or me or a lack of understanding of the history of address spaces.

My first address space was the PDP-8. That was a 12-bit address space!

Even the 8008, at 14 bits, was a step up from that.