-
Notifications
You must be signed in to change notification settings - Fork 10.6k
[WIP] Update benchmark readme #17112
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
Conversation
2b88ee0 to
5857266
Compare
|
@natecook1000 Can I get your opinion on this... have I made it clearer? |
|
@swift-ci smoke test |
|
I cannot edit this file due to permissions. When trying to push to Github Desktop, there is a JS error not allowing it, any suggestions? Based on what I know, the content looks good, I just want to make some texts fixes here and there before a merge. |
|
@Jceciliani I would just comment on the PR itself using github's review UI. |
Jceciliani
left a comment
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.
These are a few of the text changes I would recommend for this file.
benchmark/README.md
Outdated
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.
Recommended change to "of regression, micro, small, and medium sized benchmarks that are used"
benchmark/README.md
Outdated
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 are 3 ways to build the benchmark suite:"
benchmark/README.md
Outdated
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.
"NOTE: There are various levels of support here. Specifically:"
benchmark/README.md
Outdated
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.
"Non-macOS Darwin platforms today do not support the swiftpm build."
benchmark/README.md
Outdated
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.
"This is not due to intention, but rather, more engineering time would be necessary to produce these builds."
I am not entirely sure what is trying to be said here.
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.
"productization" maybe is something that we need to add to the lexicon. Basically the idea is that there are certain things that are "possible" to do with this software today that may either be fragile, unsupported, or not tested. Productization is changing the software so that it is easily usable by others.
benchmark/README.md
Outdated
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.
"to be built" or "to build"
benchmark/README.md
Outdated
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.
"SwiftBench will be a listed built product in Xcode. To find the path of"
benchmark/README.md
Outdated
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.
"in the" at the end
benchmark/README.md
Outdated
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.
sample, the test runs are significantly longer than system jitter. Due to this, we can"
benchmark/README.md
Outdated
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.
"This is done by the low level benchmark driver. It will measure the time taken for"
|
Thanks! Let me take a look at this. |
palimondo
left a comment
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 got these suggested changes. (I hope I’m using this review interface right…)
benchmark/README.md
Outdated
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.
Why leave out this option from description?
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.
This is on purpose. Iterations is an expert level feature. It confuses people as a concept and should only be progressively disclosed if necessary. This README is the right place to do that.
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 confused, did you mean “This README isn’t the right place…”?
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.
Correct.
benchmark/README.md
Outdated
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 know what exactly is meant by “system jitter” here, but this description doesn’t match my experience with Swift Benchmark Suite. This whole business with measuring average time over N iterations is the root cause of unstable results. Maybe leave out the detailed reasons for the existence of this for now as it’s subject to change?
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.
That is the intention behind why we do this, so it is appropriate. If/when we make any of the proposed changes, we can change this.
benchmark/README.md
Outdated
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.
Xcode should be spelled with capital X, there are several instances of this typo.
benchmark/README.md
Outdated
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’d write all script and command names with backticks (build-script, cmake, swiftpm) consistently in the whole document. There are multiple places where this should be fixed.
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.
swiftpm isn't a command. But I am fine with changing the rest.
benchmark/README.md
Outdated
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.
How does one control the optimization level when building with swiftpm? Maybe an example here would help?
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.
Thats reasonable.
benchmark/README.md
Outdated
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.
Non-unstable? As in stable? Or maybe “Run all benchmarks (except those tagged .unstable) for 3 samples…”
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 am also fine with this.
93041e1 to
148dc28
Compare
|
Pavol, I am not going to add the rest of that stuff. If you think it is important create a PR and it can be talked about there. I only have a limited amount of time to spend on this. |
|
*and I need to move on. I am just waiting on some feedback from @natecook1000. But I don't want to add more content to this PR. |
…ces. I added sections on running/building/removed cruft/using swiftpm to build the benchmarks standalone.
148dc28 to
8f93f73
Compare
| This directory contains the Swift Benchmark Suite. This is meant to be a suite | ||
| of regression, micro, small, and medium sized benchmarks that are used to | ||
| validate the performance of the Swift compiler and standard library. | ||
| validate the performance of the Swift compiler and standard library. There aretwo main steps to using |
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.
Typo: "aretwo" is missing a space
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.
Thanks.
| $ cmake -G Ninja \ | ||
| -DSWIFT_EXEC=$SWIFT_BUILD_DIR/bin/swiftc \ | ||
| -DSWIFT_LIBRARY_PATH=$SWIFT_BUILD_DIR/lib/macosx \ | ||
| -DCLANG_EXEC=$LLVM_BUILD_DIR/bin/clang \ |
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.
This one didn't work for me. I've set the both variables to point to the corresponding build directory, but the LLVM_BUILD_DIR isn't being picked up correctly:
CMake Error at cmake/modules/SwiftBenchmarkUtils.cmake:61 (message):
Unable to find Clang driver
Call Stack (most recent call first):
cmake/modules/AddSwiftBenchmarkSuite.cmake:27 (runcmd)
CMakeLists.txt:254 (configure_build)
which seem's to try to infer the CLANG_EXEC again from SWIFT_DARWIN_XCRUN_TOOLCHAIN. I think there's bug in AddSwiftBenchmarkSuite.cmake. Line 24 should IMO include if(NOT CLANG_EXEC) check similar the the if(NOT SWIFT_EXEC) on line 14.
|
I need to finish some stuff up today, but I am going to try and swing back around to this later today. |
|
@palimondo realistically I am not going to have time to do this. If you want to do something like this go ahead. = ). |
|
@gottesmm Can you restore this branch and let me make a fork of it first, please? |
|
@gottesmm Nevermind. I have grabbed the raw of the modified README.md. I’m good. I’ll have a look at updating and simplifying it based on this excellent rewite of yours, eventually. Thank you! |
This is a WIP to update the README to the current state of the repository.