Skip to content

Improve benchmarking for better view into perf improvements and regressions #52

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

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

mrattle
Copy link
Contributor

@mrattle mrattle commented Sep 23, 2024

TL;DR - What are you trying to accomplish?

This PR is one step towards improving the benchmarking tools available for evaluating potential performance improvements or catching regressions.

Details - How are you making this change? What are the effects of this change?

This PR uses iai-callgrind to perform analysis on CPU-level instructions, cache hits, I/O and CPU cycle estimation. Docs can be found here. This is configured to run in CI in a way that compares incoming changes against baseline performance. This level of analysis is more reliably consistent than others (e.g. wall-clock or stack-tracing benchmarks) and should be appropriate to run as part of our CI chain to help flag any potential issues with new additions to the crate. Wall-clock benchmarking through criterion-rs and stack-trace benchmarking through pprof or samply are both still valuable and coverage will be enhanced through those tools, but they are better left for use in a local environment.

@mrattle mrattle force-pushed the mrattle/better-benchmarking branch from 0739db1 to 795b482 Compare September 24, 2024 17:35
@mrattle mrattle force-pushed the mrattle/better-benchmarking branch from 795b482 to 4419610 Compare September 24, 2024 17:37
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.

1 participant