-
Notifications
You must be signed in to change notification settings - Fork 790
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multithread signature_checker #1606
Comments
Added a pull request for this #1611, it's threading the Not sure what should be set as a trivial number of verifications, I just used the number of the Seeing around a 2x speedup on my 4 core laptop.
|
@termoose thanks for the effort! This is something we would like to get in soon, so let me know if you need any help with the PR remarks. In essence we want a thread pool, where each thread is operating on 256 batched chunks. |
Hi thanks for the feedback! Will run some benchmarks with 256 sized chunks and update the the branch after testing it out. What’s the most common case? >256 verifications or less? I want to put the most common case first so we can save some cycles on returning early from this function. |
Hard to say. When bootstrapping from 0 there will be a lot, but in real-time probably not that many (at least yet). I think this task is to improve bootstrapping so I would give that priority. |
Closed the old PR, opened a new one #1614. It might be a bit faster than spawning threads each time, around 2.2x speedup on my 4 cores. We could experiment with the |
8 cores results with #1614 : 2x from 1000 (single) to 1001 (16 threads). Of course with the 256 batch size it's not using all of them. Modified the cut-off to 100k just for testing and it yields a 7.5x speedup. |
@guilhermelawless yes probably, but I'm not changing it :) |
Resolved with #1651 |
Create hardware_concurrency() number of threads and divide each signature set between the threads.
We probably don't want to divide trivial number of verifications, so some good lower-level cutoff where we'd only use one thread.
The text was updated successfully, but these errors were encountered: