leveldb-subtree
leveldb-subtree copied to clipboard
Add `Reserve` method for fixed-size write batches
Clone of https://github.com/google/leveldb/pull/1259
In case of Bitcoin Core the batch sizes at the final UTXO set are fixed (16 MiB currently). This could enable us pre-sizing the batch, if we had access to such a method, to avoid increasing memory copies at a critical time, when the memory is already saturated maximally - see https://github.com/bitcoin-dev-tools/benchcoin/pull/136.