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

Produce benchmark reports #218

Closed
kobigurk-clabs opened this issue Apr 14, 2021 · 3 comments
Closed

Produce benchmark reports #218

kobigurk-clabs opened this issue Apr 14, 2021 · 3 comments
Assignees
Labels

Comments

@kobigurk-clabs
Copy link

No description provided.

@kobigurk-clabs
Copy link
Author

  • "just add together"
  • streaming batch verification
  • decompressed signatures
  • NIZKs? (probably not)

@gtank
Copy link
Contributor

gtank commented Sep 30, 2021

The batch verification code in #222 runs benchmarks with the following paramters:

fn batch_bls_comparison(c: &mut Criterion) {
let mut group = c.benchmark_group("bls");
group.sample_size(10);
// Generate aggregate signatures on 100-validators across 1000 blocks
const NUM_BLOCKS: usize = 300;
const NUM_VALIDATORS: usize = 20;

These are NOT real benchmark results, they came from my laptop while doing other things, but the general shape is clear. Aggregate screening is faster than batch verification but does not provide the same security guarantees. Batch verification remains much, much faster than individually verifying signatures.

"per epoch aggregate" adds the signatures together for one epoch
"all epoch aggregate" does a single aggregate signature against many keys and hashes
"per epoch batch" uses the new code with a random linear combination of signatures and keys against a fixed message
"per epoch individual" validates every signature individually

bls/per-epoch aggregate screening
                        time:   [976.61 ms 980.90 ms 985.14 ms]
bls/all epoch aggregate screening
                        time:   [269.52 ms 270.88 ms 272.22 ms]
bls/per-epoch batch verification
                        time:   [1.6660 s 1.6676 s 1.6695 s]
bls/per-epoch individual verification
                        time:   [19.397 s 19.417 s 19.442 s]

@gtank
Copy link
Contributor

gtank commented Sep 30, 2021

I'll close this issue now but we can post more benchmarks in the future, for further optimization work or other modes.

@gtank gtank closed this as completed Sep 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants