Skip to content

Instantly share code, notes, and snippets.

@arthurgousset
Last active July 15, 2022 13:26
Show Gist options
  • Save arthurgousset/daa4ebc1825850f94cde3ff8ecb1a7a7 to your computer and use it in GitHub Desktop.
Save arthurgousset/daa4ebc1825850f94cde3ff8ecb1a7a7 to your computer and use it in GitHub Desktop.

💡 Lessons on comparing blockchains' "performance"

🔗 Source: Understanding Blockchain Latency and Throughput

TLDR:

Author argues 2 metrics matter for blockchain systems:

  • latency = amount of time between initiating a transaction or payment and receiving confirmation that it is valid (typically seconds)
    • lower latency (better) in 1 block finality (transaction is finalized once it gets confirmed), e.g. in classical BFT systems (e.g. PBFT, Tendermint, Tusk & Narwhal, etc)
    • higher latency (worse) in longest-chain consensus (transactions may be reorged so wait until a transaction is "k-blocks deep), e.g. in Nakamoto Consensus, Solana/Ethereum PoS.
  • throughput = load the system handles per unit of time (typically transactions per second)

You would expect latency and throughput to be inversely correlated in the form $\text{throughput} = \frac{\text{load}}{\text{latency}}$ (i.e. to be a linear on a latency/throughput graph like below), but that's not the case. Instead you observe a "hockey stick graph" or "L-graph" (the author explains why).

the key takeaway from this blog post is that we should measure in the hot zone, where both throughput and latency affect our benchmark, rather than at the edges, where only one or the other matters.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment