Add codspeed benchmarking in a dedicated CI job - #1427
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
Also add a new tox config to support running codspeed locally and in CI.
derek-globus
left a comment
There was a problem hiding this comment.
First blush with CodSpeed, I'd like to understand better how you expect this tool should fit into the sdk ecosystem.
| @@ -0,0 +1,45 @@ | |||
| name: CodSpeed Benchmarks | |||
There was a problem hiding this comment.
Does this just generate an artifact that we can inspect to more easily identify where a performance impact occurred? Or will this do something more aggressive like blocking PRs that hurt performance against prior benchmarks?
There was a problem hiding this comment.
It doesn't generate profiles or traces, but it does some sophisticated emulation work to produce stable benchmark results, which it then tracks in a project history.
It can comment on PRs which have significant performance impacts. And it defaults to blocking PRs which show a regression but I have explicitly turned that off for us. Here's how I configured it for now:
So if we have a perf regression it will tell us.
For a sample of what the PR comment looks like, I was experimenting with this in slyp over the weekend a little:
sirosen/slyp#34
There was a problem hiding this comment.
Okay, thanks; that's helpful
e8b3625 to
bb013a7
Compare
|
FWIW, I'm also new to codspeed. I'd like us to explore it, as a harness for running and tracking benchmark history, and improving our org-wide discipline. If it doesn't work out, we can remove it. |
|
I fixed the CI failure from codspeed; I was previously wrong about the cause. The |
derek-globus
left a comment
There was a problem hiding this comment.
I'm onboard to give it a try. If it becomes onerous, I may advocate that we rethink our usage, but I can see the benefit to catching performance impacts before they make it to source code.
|
FWIW, I see the value more as giving us a better way of talking about performance impacts. If I want to refactor something to be 3x larger but 10x faster, I should be able to prove that to my reviewers with a new benchmark. And we want to encode the idea that "this code is longer and more complex than other solutions because it's faster" into our testing process. |
Also add a new tox config to support running codspeed locally and in CI.