Author

Topic: Is there any benchmark results on block verification times? (Read 145 times)

legendary
Activity: 1568
Merit: 6660
bitcoincleanup.com / bitmixlist.org
Interesting project idea; but it only really seems viable to use common hardware such as 'Raspberry Pi 3B' or 'Base MacBook Pro 2016'.

The issue if categorizing by just clock speed is that a current-gen 3GHz chip is much faster than a 10 year old 3GHz chip due to ILP and other advances.
The same CPU could also perform differently on a system with faster or slower RAM, faster or slower SSD (if you verify more blocks than what fits in RAM) and similar aspects. Therefore it would probably need to be categorized by 'full system specs' like I showed above with the exact laptop or SBC model in question. An alternative would be to categorize not just by clock speed, but also by the exact model of CPU used.
Just the CPU model doesn't work either, since the same chip often exists in a higher and lower-clocked version, laptop or desktop version, overclocked or not, better or worse cooling and similar. So it has to be CPU + boost (?) clock speed at least.

Why different models of computers? We haven't even managed to enumerate most of the global models yet. It's almost impossible for someone to get ther hands on all of them.

What should be done instead, is to benchmark CPU+disk combinations, because disk performance is relevant to this application, while the speed effects of RAM are arguably negligible (data is not moving *in* frequently, which constitutes a write. Reads are fairly fast though).
legendary
Activity: 1042
Merit: 2805
Bitcoin and C♯ Enthusiast
The only correct way to benchmark is to write specialized code that targets the part you want to benchmark while mocking everything else that you don't want affecting your result (like disk IO to eliminate HDD/SSD speed). Then of course reporting the result using full system specs.
Unfortunately I'm not familiar with C++ to do it using bitcoin core and the closest thing I could find is connectblock_benchmark that targets ConnectBlock() method but that also updates UTXO set which seems to involve the database and possibly the disk IO.

However the example is showing 14 seconds for 18000 SigNet blocks which proves my first feeling was correct about my 28 seconds being too slow.
FWIW I tore my code apart and it appeared that my mock UTXO set was taking all the time (the whole 28 seconds was spent there) verification of 8000 blocks itself takes roughly 0.1 second.
legendary
Activity: 2870
Merit: 7490
Crypto Swap Exchange
Has anybody done any research about how much time it takes to verify bitcoin blocks on different hardware?

I doubt there's any research or benchmark list about it. Some time ago i asked similar thing for block size, but there's very little data about it[1].

Interesting project idea; but it only really seems viable to use common hardware such as 'Raspberry Pi 3B' or 'Base MacBook Pro 2016'.

--snip--

The result also heavily depends on which software do you use to verify block, i expect Bitcoin Core have better performance than other implementation[2]. OS and drive filesystem also have small impact.

[1] https://bitcointalksearch.org/topic/are-there-any-benchmark-about-bitcoin-full-node-client-resource-usage-5332414
[2] https://blog.lopp.net/bitcoin-core-performance-evolution/
hero member
Activity: 910
Merit: 5935
not your keys, not your coins!
Interesting project idea; but it only really seems viable to use common hardware such as 'Raspberry Pi 3B' or 'Base MacBook Pro 2016'.

The issue if categorizing by just clock speed is that a current-gen 3GHz chip is much faster than a 10 year old 3GHz chip due to ILP and other advances.
The same CPU could also perform differently on a system with faster or slower RAM, faster or slower SSD (if you verify more blocks than what fits in RAM) and similar aspects. Therefore it would probably need to be categorized by 'full system specs' like I showed above with the exact laptop or SBC model in question. An alternative would be to categorize not just by clock speed, but also by the exact model of CPU used.
Just the CPU model doesn't work either, since the same chip often exists in a higher and lower-clocked version, laptop or desktop version, overclocked or not, better or worse cooling and similar. So it has to be CPU + boost (?) clock speed at least.

It also depends how many blocks you are looking at; if it's a prolonged workload, it's not guaranteed that the chip holds the same speed at all times. So it would really need to be a pretty elaborate thing (similar to other benchmarks) where you perform multiple runs, filter out anomalies, take averages and hope to get a representative result.
legendary
Activity: 1042
Merit: 2805
Bitcoin and C♯ Enthusiast
Has anybody done any research about how much time it takes to verify bitcoin blocks on different hardware?
I'm hoping for actual values not a benchmark that I have to run myself, something like "it takes X seconds to verify block Y on CPU with clock speed Z".

For example if I remove all IO operations it would take me 28 seconds to fully verify first 2000 blocks and update databases in memory (from block #1 to #2001) on a single core @3.7 GHz.
My current assumption is that this is slow but I don't know by how much. For example should it take 5 seconds or 20?
Jump to: