Under the Hood
Loading visualizer…
DNSresolving host
TCPconnecting
TLShandshake
HTTPrequesting
Initializing Sorting Algorithms...
Sorting
Trees
Graphs
Preparing interactive visualizations...
Under the Hood
Loading visualizer…
L1/L2/L3, cache lines, hits vs misses, spatial locality — and why loop order can make identical code run several× slower
the gap between L1 and RAM is ~50×, between RAM and disk ~1000×+
A modern CPU core executes billions of instructions per second — a single clock cycle is under a nanosecond. But main RAM takes ~100 ns to answer, which is ~200+ cycles. If the CPU had to wait on RAM for every access, it would spend almost all its time stalled, twiddling its thumbs. Caches exist to close this gap.
Access latency
Active Recall
When the CPU reads one uncached byte, how much does the hardware actually fetch?