nimbus-eth2/research
Jacek Sieka b8a32419b8
async batch verification (+40% sig verification throughput) (#5176)
* async batch verification

When batch verification is done, the main thread is blocked reducing
concurrency.

With this PR, the new thread signalling primitive in chronos is used to
offload the full batch verification process to a separate thread
allowing the main threads to continue async operations while the other
threads verify signatures.

Similar to previous behavior, the number of ongoing batch verifications
is capped to prevent runaway resource usage.

In addition to the asynchronous processing, 3 addition changes help
drive throughput:

* A loop is used for batch accumulation: this prevents a stampede of
small batches in eager mode where both the eager and the scheduled batch
runner would pick batches off the queue, prematurely picking "fresh"
batches off the queue
* An additional small wait is introduced for small batches - this helps
create slightly larger batches which make better used of the increased
concurrency
* Up to 2 batches are scheduled to the threadpool during high pressure,
reducing startup latency for the threads

Together, these changes increase attestation verification throughput
under load up to 30%.

* fixup

* Update submodules

* fix blst build issues (and a PIC warning)

* bump

---------

Co-authored-by: Zahary Karadjov <zahary@gmail.com>
2023-08-03 11:36:45 +03:00
..
.gitignore wss_sim: state transition simulator (#3309) 2022-01-22 10:25:30 +01:00
block_sim.nim async batch verification (+40% sig verification throughput) (#5176) 2023-08-03 11:36:45 +03:00
block_sim.nim.cfg remove `news` leftovers (#4299) 2022-11-08 20:06:54 +00:00
fakeee.nim bump web3 (#4919) 2023-05-09 22:51:57 +00:00
mev_mock.nim initial version of mock builder relay (#5034) 2023-06-06 15:21:15 +00:00
nim.cfg enable `styleCheck:usages` (#3573) 2022-04-08 16:22:49 +00:00
simutils.nim align `MockPrivKeys` with EF keys (#4866) 2023-04-27 12:17:19 +00:00
stack_sizes.nim altair fork handling cleanups (#3050) 2021-11-05 08:34:34 +01:00
state_sim.nim segregate sync committee messages by period / fork (#4953) 2023-05-17 07:55:55 +03:00
timing.nim Local sim impovements (#4551) 2023-02-23 02:10:07 +00:00
wss_sim.nim segregate sync committee messages by period / fork (#4953) 2023-05-17 07:55:55 +03:00