Protocol-Level Pruning



Summary:

Bitcoin developer Marc suggested the concept of protocol-level pruning (PLP) to significantly reduce the size of the blockchain, which could enable on-chain scaling. The idea is to serialize the UTXO set in a standardized way and publish a hash of it in the block header so that the blockchain commits to it. When a new node joins the network, it would download the block headers only, identify the most recent block containing the UTXO set hash, and download the UTXO set from peers. Nodes would serialize and verify that their UTXO set hash matches the one published in the blockchain every 576 blocks. The serialized UTXO set is currently about 3GB, while the blockchain is about 150GB, hence PLP could cut down the amount of data stored by full nodes by a factor of approximately 50. To avoid hashing the entire UTXO set every 576 blocks, the UTXO set serialization could be a sparse merkle tree, allowing for on-the-fly recomputation of the hash as new blocks are mined. While a regular merkle tree could also suffice, sparse merkle trees would be more efficient. With PLP, all full nodes on the network could switch to it, without a need for any node to archive the entire blockchain. However, nodes would no longer be able to handle reorgs that go further back than the last UTXO set hash published on the chain since previous blocks have been discarded. Therefore, keeping around the last N*576 blocks (N=10?) may be a sufficient workaround.


Updated on: 2023-06-12T22:15:16.227154+00:00