Powershell: Use WaitForExit instead of -Wait#106216
Merged
bors merged 2 commits intorust-lang:masterfrom Dec 29, 2022
Merged
Conversation
Member
|
Why is this faster? 😕 thank you for looking into it! @bors r+ rollup |
Collaborator
Member
Author
I'm not exactly sure but the reason I tried it is because |
Member
|
Can it also be done for the alternate python detection just below please ? |
Member
Author
|
Oh good point! I missed that there were now two places. I'll create a little wrapper func to help avoid this mistake in the future. |
Member
Author
|
@bors r- |
Member
|
@bors r+ |
Collaborator
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this pull request
Dec 29, 2022
Powershell: Use `WaitForExit` instead of `-Wait` Using the method `WaitForExit` instead of the parameter `-Wait` results in a notable speed up of the `x.ps1` script (~350ms, fairly consistently). Results: ``` milliseconds before: 1127.7576 milliseconds after: 779.0467 ``` I think there are opportunities for further speed up by calling `Get-Command` only once with the pattern `py*` then filtering the returned list. But I'll leave that for another time (or someone else). r? `@jyn514`
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Dec 29, 2022
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#106208 (Make trait/impl `where` clause mismatch on region error a bit more actionable) - rust-lang#106216 (Powershell: Use `WaitForExit` instead of `-Wait`) - rust-lang#106217 (rustdoc: remove unnecessary `.tooltip::after { text-align: center }`) - rust-lang#106218 (Migrate css var scraped examples) - rust-lang#106221 (Rename `Rptr` to `Ref` in AST and HIR) - rust-lang#106223 (On unsized locals with explicit types suggest `&`) - rust-lang#106225 (Remove CraftSpider from review rotation) - rust-lang#106229 (update Miri) - rust-lang#106242 (Detect diff markers in the parser) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Aaron1011
pushed a commit
to Aaron1011/rust
that referenced
this pull request
Jan 6, 2023
…iaskrgr Rollup of 9 pull requests Successful merges: - rust-lang#106208 (Make trait/impl `where` clause mismatch on region error a bit more actionable) - rust-lang#106216 (Powershell: Use `WaitForExit` instead of `-Wait`) - rust-lang#106217 (rustdoc: remove unnecessary `.tooltip::after { text-align: center }`) - rust-lang#106218 (Migrate css var scraped examples) - rust-lang#106221 (Rename `Rptr` to `Ref` in AST and HIR) - rust-lang#106223 (On unsized locals with explicit types suggest `&`) - rust-lang#106225 (Remove CraftSpider from review rotation) - rust-lang#106229 (update Miri) - rust-lang#106242 (Detect diff markers in the parser) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Using the method
WaitForExitinstead of the parameter-Waitresults in a notable speed up of thex.ps1script (~350ms, fairly consistently).Results:
I think there are opportunities for further speed up by calling
Get-Commandonly once with the patternpy*then filtering the returned list.But I'll leave that for another time (or someone else).
r? @jyn514