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
Adopt package-benchmark
#2534
Adopt package-benchmark
#2534
Conversation
7ad8c8f
to
af255af
Compare
@@ -0,0 +1,9 @@ | |||
.DS_Store |
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.
Can we nest Benchmarks
in IntegrationTests
instead of the root of the repo?
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.
I intentionally did not nest it since I expect us to migrate all of them at some point and having it at the top level is way nicer. This also follows what we do in other packages.
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.
I don't think that's a good reason given IntegrationTests
contains more than just allocation tests.
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.
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.
I'm ok with having them at the top level.
af255af
to
a649ec8
Compare
a649ec8
to
575d15d
Compare
575d15d
to
7b73f08
Compare
scalingFactor: .mega | ||
) | ||
) { benchmark in | ||
try runTCPEcho(numberOfWrites: 10_000) |
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.
Scalingfactor 1M but writing 10K? Perhaps consider numberOfWrites to be scalingfactor if you want to make sense of output from --scale later. Otherwise probably skip setting scalingfactor here, as it's really intended for inner loops in practice.
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.
So I set the scaling factor because with the default the p90 was to flaky for allocations. With .mega
scaling factor they seem really stable. I just pushed a commit that uses the scaledIterations.upperBound
for the number of writes
# Motivation We want to migrate our allocation and later on also our performance tests to use the `package-benchmark` plugin. This plugin makes writing benchmarks way easier than our current setup. Furthermore, debugging benchmarks is also possible from within Xcode now. # Modification This PR adds the setup for the benchmarking infrastructure and connects it with out # Result Allocations tests are more accessible and easier to iterate.
7b73f08
to
7263385
Compare
Motivation
We want to migrate our allocation and later on also our performance tests to use the
package-benchmark
plugin. This plugin makes writing benchmarks way easier than our current setup. Furthermore, debugging benchmarks is also possible from within Xcode now.Modification
This PR adds the setup for the benchmarking infrastructure and connects it with out
Result
Allocations tests are more accessible and easier to iterate.