gballet / go-ethereum

Official Go implementation of the Ethereum protocol
https://geth.ethereum.org
GNU Lesser General Public License v3.0
23 stars 13 forks source link

shower thought: store the top of the tree as a single node #448

Open gballet opened 5 months ago

gballet commented 5 months ago

in the new path-based storage model, we have a series of layers, to represent updates to the tree. the top layer will always be updated, so it makes sense to store all of it in a single field and save many key, values and therefore many writes. only write about 8kb of data... or don't even store it into the db.

gballet commented 5 months ago

another idea is to store it with compressed points, as these points can be serialized/deserialized together, thus amortizing the cost.