Summary and TL;DRBlockchain "throughput" is often measured in Transactions Per Second (TPS), but transactions are a poor indicator of useful actions. It's counterintuitive, but on blockchains with high percentages of batch transactions like Bitcoin, the most efficient blocks actually have the lowest TPS. For example, the theoretically most-efficient 4M WU Bitcoin block would consist of 1 single transaction packed with 32250 individual 31-vByte P2WPKH Bech32 UTXO output addresses. This would make Bitcoin a 0.002 TPS network despite performing at a much-higher 53.7 useful Transfers Per Second (TfrPS), which is a better metric for useful actions. In this analysis of over 2 million Bitcoin transactions, I determined that if Bitcoin's blocks were 100% filled, its TPS throughput given the current mix of transaction types is a disappointing 3.9 TPS. This is a major limitation because if even 1% of the world's population used Bitcoin, they would only be able to make 1 on-chain transaction once every 240 days. However, this metric is misleading due to batch transactions. About 20% of transactions on the Bitcoin network use batching, and this is enough to effectively increases useful throughput from 3.9 TPS to 16.8 TfrPS (still slow, but noticeably higher). (While this analysis focuses on Bitcoin, other blockchains are also able to do this. But this post is already too long to include a comprehensive analysis of multiple blockchains. This was researched to the best of my knowledge. Please let me know if you spot any errors.) Theoretical Limit of Batching Ouputs Theoretical Limit of Batching Inputs Intro - Throughput BenchmarksThroughput is the rate at which data travels through a network. For cryptocurrency networks, this is often measured by Transactions Per Second (TPS) because that's the easiest metric to measure on all networks, and the data is ubiquitous. But this is an inadequate measurement of throughput because it doesn't reflect the true rate of useful actions. Benchmarks: For gaming computers, there is no single benchmark that covers everything. Instead, they are divided into many different categories such as: single-CPU, multi-CPU, 2D graphics, 3D graphics, physics, ray-tracing, etc. There are also composite benchmarks that attempt to estimate typical usage like: office use, gaming use, watching media, video editing, 3D modeling. One way of benchmarking crypto throughput is to divide into different types of "useful actions". Useful action: A useful action could be a transfer, swap, NFT mint, contract create/destroy, deposit/withdrawal. For batch transactions, a single batch transaction could contain 5000 useful actions, and a single contract could create 100 NFT mints. So what looks like 1 TPS could actually be 5000 useful Transfers Per Second, which I'll call TfrPS. Useful action in Bitcoin: Bitcoin does not support advanced smart contracts, so there is only one type of useful action: a transfer. You'd think it would be one of the easier blockchains to benchmark. However, this is far from true due to the numerous different types of addresses. Bitcoin now has P2PKH, P2SH, P2WPKH, P2WSH, P2WPKH/P2WSH-within-P2SH, and P2TR addresses, all with different input sizes, output sizes, and signature/witness sizes. This is due to the Bitcoin community's ridiculously unhealthy obsession with avoiding hard forks (e.g. the Segwit 4M weight fiasco that inevitably ended up splitting the community in a hard fork anyways). Each of the combinations of addresses and headers generates a different size of transactions, each with different TPS and TfrPS measurements. (So Bitcoin, please Go Hard FORK yourself and get rid of all these outdated, inefficient address types.) About 20% of Bitcoin transactions are batch transactions, which I consider any transaction with more than 3 UTXOs. These are almost exclusively done by exchanges. I've personally noticed BlockFi and Gemini doing small batch transactions of ~10 UTXOs with my accounts, and Coinbase doing a 1:100 batch transaction with them. AnalysisTools: Most of my data is from blockchair.com, blockchain.com, blockstream.info, and btcscan.org for analyzing blocks and transactions. Blockchair was particularly useful because it provides a bulk TSV data download way faster than most API services. Gotta love the speed of traditional databases. I used Google Sheets to compile the results, which was annoyingly slow due to its 10M-cell limit, so I had to optimize by splitting calculations across multiple sheets. Lastly, I used this calculator to double-check my work. Overall Measurements from the Blockchain: Overall, across 1271 blocks and 2.19M transactions, there were 1.47B bytes, 3.82B weight units (WU), and 9.60B transfers. On average, the blocks would've been 1.54MB on average if full. The actual TPS with the partially-full blocks was 2.88. Had the blocks been full, they would have seen a throughput of 3.9 TPS and 16.8 TfrPS. Transaction count varies as much as 10% from day to day. However, the results after correcting for block fullness are quite stable.
What this means is that the Bitcoin blockchain is getting 3.3x more useful actions (TfrPS) than what the TPS metric suggests. Frequency of Transaction Types Transfers per Transaction: Most single-transfer transactions actually contain 3 UTXOs instead of 2 because there is a leftover change UTXO. Within the 2M transactions, here's the percent breakdown of what kind of transactions were on the blockchain:
Size DetailsBlock size: Each Bitcoin block has a maximum of 4M weight units (WU), mined an average of once per 10 minutes or 6667 WU/s. On average, 75% of the daily block space was filled. Transaction weight = 3x base size + 1x full size = 4x (header + inputs + outputs) + 1x witness size UTXO sizes (vBytes)
Common Transaction WeightsThese are the UTXO combinations I noticed the most often in the 400-1000 WU range. Almost all batch transactions fall beyond this range, and they vary too much in size to be included here. The largest ones were ~400000 WU.
βDistribution of Transactions by Weight Units Theoretical Limits to Batch throughput
Batching Outputs - Throughput
Batching Inputs - Throughput
Side NotesOutliersSmallest transactions: Technically, the smallest transactions are [396-397 WU, 1:1 P2TR (Taproot) to P2WPKH] transactions, but they're very rare (< 0.5% of transactions), and they're not used in batch transactions. So they're not relevant to this analysis. Largest transactions: Technically, the largest batch transactions date back to 2015. They each held 20000 transfers like this one: 30b3b19b4d14fae79b5d55516e93f7399e7eccd87403b8dc048ea4f49130595a, but they were useless wasted block space sent to OP_RETURN without any metadata. If anyone knows the history behind these transactions, please enlighten me. [link] [comments] |
You can get bonuses upto $100 FREE BONUS when you:
π° Install these recommended apps:
π² SocialGood - 100% Crypto Back on Everyday Shopping
π² xPortal - The DeFi For The Next Billion
π² CryptoTab Browser - Lightweight, fast, and ready to mine!
π° Register on these recommended exchanges:
π‘ Binanceπ‘ Bitfinexπ‘ Bitmartπ‘ Bittrexπ‘ Bitget
π‘ CoinExπ‘ Crypto.comπ‘ Gate.ioπ‘ Huobiπ‘ Kucoin.
Comments