-
-
Notifications
You must be signed in to change notification settings - Fork 71
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
Introduce benchmark + performance regression checks #195
Comments
some functions will always be slower than core ( e.g: |
Obviously, Psl will always be slower than core: it is required to keep the baseline under control though, as performance regressions often go unnoticed. Also, knowing how much slower the library is allows for downstream consumers to take an informed decision as to when/where to use it. |
r.e. running in CI - I'm doing this with a bash script with assertions at a tolerance of 10% (but this is too optimistic, 15% might be better). It's still an experimental area (i also tried two separate actions to combine their results, but this doesn't work as the actions can run in completely different envs I guess). |
Sounds feasible - even with a very high tolerance, it's more about looking at it before releasing, I guess? Intra-worker performance should be relatively stable |
with a 15% tolerance it should catch obvious regressions, I guess if you want to check more subtly then before release/at PR time.
as in 2 actions? at least for me (the one time i tried it) this resulted in less stable results |
No no, same action and container: nothing guarantees that you will get two boxes running on a similar hardware otherwise. |
As
Psl\
grows in size and adoption, its performance becomes one important evaluation point when considering it for downstream adoption.This question came up in both #194 and Roave/BackwardCompatibilityCheck#306, and it would be a good idea to have reference/comparison.
The idea is to have following benchmarks:
For that, it would be interesting to use https://github.com/phpbench/phpbench/tree/1.0.1
@dantleech do you know if there is a sensible way to run benchmarks and compare them in CI? That's something that is kinda missing within PHPBench' docs 🤔
The text was updated successfully, but these errors were encountered: