cculianu / Fulcrum

A fast & nimble SPV Server for BCH, BTC, and LTC
Other
325 stars 73 forks source link

SynchMempoolTask: Add parallel UTXO precacher for perf. benefit of up to ~30% + BugFix #207

Closed cculianu closed 8 months ago

cculianu commented 8 months ago

We add a parallel UTXO precache mechanism to the SynchMempoolTask. This mechanism looks UTXOs up in the utxodb as we are busy downloading mempool txns from bitcoind. The benefit is not large for small mempools but on e.g. BTC with ~140k txns in the mempool, the performance benefit is up to ~33% over existing code. This is because we utilize the disk and CPU concurrently with the network while downloading large mempools.


Also in this PR: