Skip to content
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

ProtocolKeyRegistration creates performance bottleneck in aggregator #1187

Closed
3 tasks done
jpraynaud opened this issue Aug 29, 2023 · 0 comments · Fixed by #1295
Closed
3 tasks done

ProtocolKeyRegistration creates performance bottleneck in aggregator #1187

jpraynaud opened this issue Aug 29, 2023 · 0 comments · Fixed by #1295
Assignees
Labels
performances 🥇 Performances

Comments

@jpraynaud
Copy link
Member

jpraynaud commented Aug 29, 2023

Issue

During our stress test benchmarks of the aggregator, we have noticed that a bottleneck probably exists with the ProtocolKeyRegistration which is done for each new signature sent to the aggregator. Its creation is resource intensive and leads to quadratic computations. This could be easily fixed by memoizing the ProtocolKeyRegistration which is the same for all the signatures during an epoch

To do

  • Add a service to hold a precomputed ProtocolMultiSigner (or SignerBuilder) for the current epoch
  • Use this cached ProtocolMultiSigner in the multi signer functions verify_single_signature and create_multi_signature
  • Verify that the delay to ingest delay for signatures of 500 signers in the aggregator has significantly dropped
@jpraynaud jpraynaud added dev 💪 optimization 🛠️ Optimization and/or small enhancements to-groom 🤔 Needs grooming performances 🥇 Performances labels Aug 29, 2023
@jpraynaud jpraynaud removed dev 💪 optimization 🛠️ Optimization and/or small enhancements labels Sep 21, 2023
@jpraynaud jpraynaud removed the to-groom 🤔 Needs grooming label Oct 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performances 🥇 Performances
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants