Latency numbers every programmer should know

Published: (February 28, 2026 at 07:58 AM EST)
1 min read

Source: Hacker News

Cache latencies

  • L1 cache reference: 1 ns
  • L2 cache reference: 4 ns
  • Branch mispredict: 3 ns

Memory latency

  • Main memory reference: 100 ns
  • Read 1 000 000 bytes sequentially from memory: 741 ns

Disk / SSD latencies

  • SSD sequential read: 12.245 µs
  • SSD random read: 16.0 µs
  • Read 1 000 000 bytes sequentially from SSD (disk): 358.968 µs
  • Disk seek: 1.649 ms

Synchronization

  • Mutex lock / unlock: 16 ns

Network latencies

  • Send 2 000 bytes over a commodity network: 5 ns (per byte overhead)
  • Round‑trip within the same datacenter: 500 µs
  • Packet round‑trip (CA → Netherlands): 150 ms

References

  • [github.com/chubin/late.nz] – MIT License
  • Console port of “Jeff Dean’s latency numbers”
  • Source: [github.com/colin-scott/interactive_latencies]
0 views
Back to Blog

Related posts

Read more »