Must know numbers for every computer engineer

Image for post
Image for post

In 2010, Jeff Dean from Google gave a wonderful talk in Standford & he discussed few numbers of computing systems, he got really famous for that. Peter Norvig published those numbers for the first time in the internet. Time passes away, so the numbers also change. I found a very good interactive web UI of those numbers which roughly tell how much those numbers have changed over the years as a function of time.

This article is a compilation of not only Jeff Dean’s estimated data, rather of all such numbers from different sources which may help you as a system designer & architect. While designing, you can use these numbers to estimate the amount of resources your system needs.

  1. L1 cache reference: 1 nanosecond.
  2. L2 cache reference: 4 nanosecond.
  3. Mutex Lock / Unlock: 17 nanosecond.
  4. Main memory / RAM reference: 100 nanosecond.
  5. Compress 1 KB with Zippy (currently called Snappy): 2000 nanosecond or 2 microsecond.
  6. CPU branch mispredict: 3 nanosecond.
  7. Solid State Drive (SSD) random read: 16 microsecond.
  8. Disk (Hard drive / magnetic drive) seek: 3 millisecond.
  9. Read 1,000,000 bytes sequentially from main memory: 4 microsecond.
  10. Read 1,000,000 bytes sequentially from SSD: 62 microsecond.
  11. Read 1,000,000 bytes sequentially from disk: 947 microsecond.
  12. Round trip network request in same data centre : 500 microsecond.
  13. Send 2000 bytes over commodity network: 62 nanosecond.

Here is the amount of time required to transmit various data payloads on typical cell networks around the world assuming no data loss.

RTT — Round Trip Time — Total time taken for a data packet (bunch of data bytes) to travel from sender to receiver & receiver to sender over the network. In short, it’s called Ping time.

  1. Transfer of 1 byte to 13,000 bytes (roughly 13 KB) data takes 1 round trip or 1 RTT. Rough time taken in USA: 150 millisecond, India: 1200 millisecond, Brazil: 600 millisecond.
  2. 13,001 bytes — 39,000 bytes (13 KB to 39 KB) takes 2 RTT. Rough time taken — USA: 300 millisecond, India: 2400 millisecond, Brazil: 1200 millisecond.
  3. 39,001 bytes — 91,000 bytes (39 KB to 91KB) takes 3 RTT. Rough time taken-USA: 450 millisecond, India: 3600 millisecond, Brazil: 1800 millisecond.
  4. 91,001 bytes — 195,000 bytes (91 KB to 195 KB) takes 4 RTT. Rough time taken — USA: 600 millisecond, India: 4800 millisecond, Brazil: 2400 millisecond.

So more the response size, more bytes, more round trip, more the API latency, less user friendly app. :(

This post will be updated as and when new or updated numbers are found. Please let me know if you are aware of new numbers.

Reference:

  1. https://colin-scott.github.io/blog/2012/12/24/latency-trends/
  2. https://blog.std.in/2015/05/23/http-response-sizes-and-tcp/

Written by

Deep discussions on problem solving, distributed systems, computing concepts, real life systems designing. Developer @PayPal. https://in.linkedin.com/in/kousikn

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store