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

Benchmarks: report tx/s as elements/s #345

Merged
merged 1 commit into from
Sep 30, 2023

Conversation

gefjon
Copy link
Contributor

@gefjon gefjon commented Sep 29, 2023

Description of Changes

Based on my limited understanding of Criterion, I think we can get add transactions per second reporting to benchmarks using Criterion's Throughput::Elements tracking, by treating transactions as elements.

This is not ideal, as the output says e.g. thrpt: [38.763 Kelem/s 38.781 Kelem/s 38.799 Kelem/s], where we'd like Ktx/s, but it's not clear whether Criterion allows us that much customization.

Each of the benchmarks currently does one tx per iteration, so pass Throughput::Elements(1) for each of them. Do this as close to the test as possible, despite redundancy, in case we ever add benchmarks to the same group which do multiple transactions per iteration.

API and ABI

  • This is a breaking change to the module ABI
  • This is a breaking change to the module API
  • This is a breaking change to the ClientAPI
  • This is a breaking change to the SDK API

If the API is breaking, please state below what will break

Based on my limited understanding of Criterion,
I think we can get add transactions per second reporting to benchmarks
using Criterion's Throughput::Elements tracking,
by treating transactions as elements.

This is not ideal, as the output says e.g.
`thrpt:  [38.763 Kelem/s 38.781 Kelem/s 38.799 Kelem/s]`,
where we'd like `Ktx/s`,
but it's not clear whether Criterion allows us that much customization.

Each of the benchmarks currently does one tx per iteration,
so pass `Throughput::Elements(1)` for each of them.
Do this as close to the test as possible, despite redundancy,
in case we ever add benchmarks to the same group
which do multiple transactions per iteration.
@gefjon gefjon requested a review from kazimuth September 29, 2023 23:22
@cloutiertyler
Copy link
Contributor

benchmarks please

Copy link
Contributor

@cloutiertyler cloutiertyler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@cloutiertyler cloutiertyler merged commit 97ed85e into master Sep 30, 2023
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants