-
Notifications
You must be signed in to change notification settings - Fork 471
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
Tools: Add benchmark warnings for PRs and push graphs for commits into master #3998
Conversation
Codecov Report
@@ Coverage Diff @@
## master #3998 +/- ##
==========================================
+ Coverage 49.77% 54.45% +4.67%
==========================================
Files 409 390 -19
Lines 69157 48500 -20657
==========================================
- Hits 34426 26411 -8015
+ Misses 31011 19868 -11143
+ Partials 3720 2221 -1499
Continue to review full report at Codecov.
|
@michaeldiamant thanks for the quick review and explanations for your reasoning - I agreed with all the comments and addressed them in the latest PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@algochoi Thanks for the effort here - I'm excited to collect data and gain experience with the tooling! ☕
Summary
This PR adds a github action to track performance regressions for the
BenchmarkUintMath
benchmark.Workflows
The PR introduces two github workflows:
master
branch and comment on the PR if it is over a particular threshold (default: 200%). An example comment for the performance alert can be seen [here].(Check workflow against commits on master algochoi/go-algorand#10 (comment)).master
branch, push and persist performance metrics to thegh-pages
branch ,and visualize any improvements or regressions over time (will be available at: https://algorand.github.io/go-algorand/dev/bench/).Variance
There is some variance between runs because github actions might spin up a different machine each time (e.g. Intel Xeon
8370C
vs8171M
). Empirically, the variance seems to be 10~30% for the most part. We tried putting some baseline benchmarks (e.g.sleep(1s)
), but the variance in sleeping between machines is extremely low to provide any useful metric.Time series visualization
The github-actions-benchmark tool we used provides a graph to visualize performance benchmark. It requires permissions to push to the
gh-pages
branch and can show trends over commits in themaster
branch. An example in a local repo can be seen here.Future work
BenchmarkUintMath
, but it could be useful to track other benchmarks in the future to see any regressions/improvements over time.github-action-benchmark
tool we used.Test Plan
Tested on a local fork and branch. Example PR for the performance alert can be seen here.
Closes an internal ticket