How a computer really works, layer by layer.
Start from the apps you use and the algorithms behind them, then follow a single line of C down through assembly, machine code, micro-operations and buses to the logic gates and transistors that run it, and step through every one of them live.
- levels of abstraction
- 10
- levels of abstraction
- chapters planned
- 84
- chapters planned
- runnable examples
- 24
- runnable examples
- installs or sign-ups
- 0
- installs or sign-ups
The simulator
Stop imagining what the CPU does. Watch it.
A compiler, an emulator and a debugger that explain themselves, running entirely in your browser.
C → assembly, in your browser
A real compiler with types, pointers, structs and strings. Every assembly line maps back to the C that produced it.
cmp eax, 5 · 3 − 5 = −2 → jl taken
Every flag, every bit
The full RFLAGS register, what each instruction wrote or changed, and which conditional jump will be taken, and why.
The stack, labeled
Frames, locals, arguments, saved frame pointers and return addresses, named from your C source. Watch a buffer overflow smash one.
Inside the CPU
Fetch, decode, address calculation, bus reads and writes, ALU, write-back: each micro-operation animated on the system bus.
Ten levels
From a click to an electron, ten levels deep
Every level is implemented by the one below it. Pick any level to zoom in.
Explore the ten levels- L0Applications & the userWhat you see and do: clicking, typing, loading a page, and what each of those really sets in motion.
double-click → app - L1Problems & algorithmsBefore any language: what a computation is, how to solve a problem step by step, and how to measure the cost.
sort(list) - L2Programming languagesWhat you write: variables, functions, pointers, and what a compiler turns them into.
c = a + b; - L3Assembly languageOne line per instruction: registers, flags, jumps: the view debuggers and disassemblers give you.
add eax, ecx - L4Operating systemThe layer that turns one CPU into many processes: virtual memory, system calls, files.
syscall - L5Instruction set architectureThe contract between software and silicon: instruction formats, encodings, addressing modes.
01 C8 - L6MicroarchitectureHow one instruction becomes fetch, decode, execute: datapath, buses, caches and pipelines.
MAR ← rip · MEMR - L7Digital logicGates, adders, the ALU, flip-flops and memory cells, where 0 and 1 become arithmetic.
S = A ⊕ B ⊕ Cin - L8Devices & chipsTransistors as switches, CMOS gates, how chips are made, and the storage and I/O devices built from them.
NMOS · PMOS - L9Physics of computingThe real bottom: electrons, semiconductors and the field effect: how a bit is physically stored and moved, and the limits physics sets.
e⁻ · p-n
Foundations
The number systems every level relies on.
Start at the top. Go as deep as you like.
No install, no account. Every chapter has live demos to play with.
Start with the levels