MPS LABS · HUNT VALLEY, MARYLAND · 1991 & 1994
A WORLD IN 640K
Sid Meier's Civilization (1991) and Sid Meier's Colonization (1994) each simulate centuries of a planet — terrain, nations, economies, war. Colonization ships 4.34 MB of decompressed art and roughly 450 KB of program, for machines whose entire arena for program, data and stack was 640 KB minus DOS. This site is the byte-level story of how it was done.
The wall
Every DOS program was born into the same room. IBM's original PC handed the 8088's 20-bit address bus a single megabyte of address space and drew a line at 640 KB: below it, RAM for DOS and whatever you ran; above it, 384 KB reserved for hardware — video apertures, adapter ROMs, the system BIOS. As the Digital Antiquarian's Jimmy Maher puts it, IBM's engineers “reserved big chunks of ‘special’ memory for purposes that hadn't even been imagined yet”. In 1981 the split looked generous. Within a decade it was simply the wall, and every PC game was engineered against it.
The map below is that megabyte as both games found it. Note how little of it the games actually own: the amber band is everything — code, data, stack, decompression buffers, a planet. Hover any region for what it does.
The industry's escape hatch was expanded memory. EMS — announced by Lotus, Intel and
Microsoft in 1985 — bank-switched 16 KB pages of extra RAM through a 64 KB window
in the reserved area: four movable “lenses” aimed at megabytes the CPU could not otherwise
address. Bill Gates, signing Microsoft up, as reported by Maher: “It's garbage! It's a
kludge! But we're going to do it.” Extended memory (XMS) later offered honest block-copies
above 1 MB, and DOS 5's DOS=HIGH parked part of the kernel in the
65,520-byte high memory area — a region that exists only because the 286's A20 address line
fails to wrap the way an 8088's did — handing programs back up to 46 KB of the arena.
None of it moved the wall. A mid-range 1994 PC carried 4 MB of RAM behind a 486DX2-66; Colonization's manual still demands “at least 575,000 bytes of free conventional memory” — a requirement you met by editing CONFIG.SYS, not by buying hardware. Entire product categories (QEMM, MemMaker) existed to win back tens of kilobytes of that band. The two games on this site are what disciplined engineering looks like inside it.
Two games, two answers
MicroProse solved the arena twice, three years apart. Civilization is close to a solo work — “I did just about all the coding,” Meier told Game Developer — a 304,512-byte real-mode executable whose code is split into 23 overlays by Microsoft LINK's interrupt-driven overlay scheme. Colonization, written largely by Brian Reynolds, is one linker generation later: its 493,470-byte viceroy.exe carries a software virtual-memory system — RTLink/Plus — that demand-pages 31 chunks of code through an LRU pool, patching its own call sites as it goes.
| Civilization | Colonization | |
|---|---|---|
| Shipped | 1991 · CIV.EXE, 304,512 B | 1994 · viceroy.exe, 493,470 B |
| Video | EGA / MCGA / VGA / Tandy — swappable driver EXEs | VGA Mode 13h (320×200×256) |
| Resident need | 237,967 B minimum root footprint (~232 KB); MaxAlloc = FFFF, take everything | ~168 KB ask — MaxAlloc pinned 512 B above MinAlloc; never grows |
| Overlay tech | Microsoft LINK INT 3Fh — 23 overlays, 121,720 B, one resident at a time | RTLink/Plus VM — 31 demand-paged code pages, 361,168 B, LRU pool, 1,031 thunks |
| Asset codec | .PIC tagged blocks — LZW + RLE | MADSPACK 2.0 containers — FAB, 4 KB window |
| EMS use | none — runs entirely in conventional memory | optional — page cache for code; intro audio streamed through the page frame |
| World state | every save exactly 37,856 B; terrain in a .MAP stored via the art codec | ≈24 KB live; the colony09.sav save is 25,311 B, byte-exact |
The chapters
Seven chapters, each built around figures that move. The numbers in them are measured, not remembered.
How to read this site
Chapters 1–3 are the machinery: how the code, the memory and the art were made to fit. Chapters 4–6 are the simulation: how a world small enough to store became big enough to matter. Chapter 7 is the method. Every number on the site is measured — read out of the shipped bytes in fresh 2026 analysis, or observed in live instrumented runs under mddosem, the hardware-accurate PC emulator (written in Rust) that serves as our instrument. Where community lore and the bytes disagreed, the bytes won. Errors are ours; corrections are welcome.
Sources for this page — era & quotes: The Digital Antiquarian, Quote Investigator, Game Developer (2007), the Colonization manual; byte-level: fresh 2026 analysis of the CIV.EXE and viceroy.exe installs; runtime: live PIT and IVT captures under mddosem. Full credits in How We Know.