Skip to content
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

Replace &Vec<_>s with &[_]s #97697

Merged
merged 2 commits into from
Jun 5, 2022
Merged

Replace &Vec<_>s with &[_]s #97697

merged 2 commits into from
Jun 5, 2022

Conversation

WaffleLapkin
Copy link
Member

It's generally preferable to use &[_] since it's one less indirection and it can be created from types other that Vec.

I've left &Vec in some locals where it doesn't really matter, in cases where TypeFoldable is expected (TypeFoldable: Clone so slice can't implement it) and in cases where it's &TypeAliasThatIsActiallyVec. Nothing important, really, I was just a little annoyed by visit_generic_param_vec :D

r? @compiler-errors

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Jun 3, 2022
@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jun 3, 2022
@compiler-errors
Copy link
Member

I don't expect this to show anything but noise but worth a shot

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jun 3, 2022
@bors
Copy link
Contributor

bors commented Jun 3, 2022

⌛ Trying commit afaa985 with merge c2567afd60370409f05b8c2d8e0baf9f45f6764c...

@bors
Copy link
Contributor

bors commented Jun 3, 2022

☀️ Try build successful - checks-actions
Build commit: c2567afd60370409f05b8c2d8e0baf9f45f6764c (c2567afd60370409f05b8c2d8e0baf9f45f6764c)

@rust-timer
Copy link
Collaborator

Queued c2567afd60370409f05b8c2d8e0baf9f45f6764c with parent e40d5e8, future comparison URL.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (c2567afd60370409f05b8c2d8e0baf9f45f6764c): comparison url.

Instruction count

  • Primary benchmarks: 🎉 relevant improvement found
  • Secondary benchmarks: 🎉 relevant improvements found
mean1 max count2
Regressions 😿
(primary)
N/A N/A 0
Regressions 😿
(secondary)
N/A N/A 0
Improvements 🎉
(primary)
-0.3% -0.3% 1
Improvements 🎉
(secondary)
-0.7% -0.8% 6
All 😿🎉 (primary) -0.3% -0.3% 1

Max RSS (memory usage)

Results
  • Primary benchmarks: 🎉 relevant improvement found
  • Secondary benchmarks: 🎉 relevant improvement found
mean1 max count2
Regressions 😿
(primary)
N/A N/A 0
Regressions 😿
(secondary)
N/A N/A 0
Improvements 🎉
(primary)
-3.0% -3.0% 1
Improvements 🎉
(secondary)
-2.4% -2.4% 1
All 😿🎉 (primary) -3.0% -3.0% 1

Cycles

This benchmark run did not return any relevant results for this metric.

If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf.

Benchmarking this pull request likely means that it is perf-sensitive, so we're automatically marking it as not fit for rolling up. While you can manually mark this PR as fit for rollup, we strongly recommend not doing so since this PR may lead to changes in compiler perf.

@bors rollup=never
@rustbot label: +S-waiting-on-review -S-waiting-on-perf -perf-regression

Footnotes

  1. the arithmetic mean of the percent change 2

  2. number of relevant changes 2

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jun 3, 2022
@compiler-errors
Copy link
Member

Cool. @WaffleLapkin, r=me with those comments addressed above.

@bors delegate+

@bors
Copy link
Contributor

bors commented Jun 3, 2022

✌️ @WaffleLapkin can now approve this pull request

@WaffleLapkin
Copy link
Member Author

@bors r+

@bors
Copy link
Contributor

bors commented Jun 5, 2022

📌 Commit cae3c78 has been approved by WaffleLapkin

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 5, 2022
@bors
Copy link
Contributor

bors commented Jun 5, 2022

⌛ Testing commit cae3c78 with merge 4322a78...

@bors
Copy link
Contributor

bors commented Jun 5, 2022

☀️ Test successful - checks-actions
Approved by: WaffleLapkin
Pushing 4322a78 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jun 5, 2022
@bors bors merged commit 4322a78 into rust-lang:master Jun 5, 2022
@rustbot rustbot added this to the 1.63.0 milestone Jun 5, 2022
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (4322a78): comparison url.

Instruction count

  • Primary benchmarks: 🎉 relevant improvement found
  • Secondary benchmarks: no relevant changes found
mean1 max count2
Regressions 😿
(primary)
N/A N/A 0
Regressions 😿
(secondary)
N/A N/A 0
Improvements 🎉
(primary)
-0.6% -0.6% 1
Improvements 🎉
(secondary)
N/A N/A 0
All 😿🎉 (primary) -0.6% -0.6% 1

Max RSS (memory usage)

Results
  • Primary benchmarks: no relevant changes found
  • Secondary benchmarks: mixed results
mean1 max count2
Regressions 😿
(primary)
N/A N/A 0
Regressions 😿
(secondary)
2.3% 2.6% 2
Improvements 🎉
(primary)
N/A N/A 0
Improvements 🎉
(secondary)
-4.6% -4.6% 1
All 😿🎉 (primary) N/A N/A 0

Cycles

Results
  • Primary benchmarks: 😿 relevant regression found
  • Secondary benchmarks: no relevant changes found
mean1 max count2
Regressions 😿
(primary)
2.6% 2.6% 1
Regressions 😿
(secondary)
N/A N/A 0
Improvements 🎉
(primary)
N/A N/A 0
Improvements 🎉
(secondary)
N/A N/A 0
All 😿🎉 (primary) 2.6% 2.6% 1

If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf.

@rustbot label: -perf-regression

Footnotes

  1. the arithmetic mean of the percent change 2 3

  2. number of relevant changes 2 3

@compiler-errors
Copy link
Member

not a big deal, but next time @WaffleLapkin write r=compiler-errors instead of r+ so the merge commit says that i approved it.

it's just the merge commit title, though, so not a problem.

@WaffleLapkin WaffleLapkin deleted the no_ref_vec branch June 5, 2022 13:28
@WaffleLapkin
Copy link
Member Author

Ah, ok

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants