-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Use AttrVec
more
#100668
Use AttrVec
more
#100668
Conversation
Some changes occurred in src/tools/rustfmt cc @rust-lang/rustfmt Some changes occurred in src/librustdoc/clean/types.rs cc @camelid |
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
⌛ Trying commit 10127a2e4f63aac6abbfe354a60bca49e700b4b5 with merge ea19f197d57a419f4310951e073202e05bbe3615... |
This comment has been minimized.
This comment has been minimized.
SIGILL here too? Is this from my changes (I haven't touched any |
☀️ Try build successful - checks-actions |
Queued ea19f197d57a419f4310951e073202e05bbe3615 with parent 86c6ebe, future comparison URL. |
Finished benchmarking commit (ea19f197d57a419f4310951e073202e05bbe3615): comparison url. Instruction count
Max RSS (memory usage)Results
CyclesResults
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. Next Steps: If you can justify the regressions found in this try perf run, please indicate this with @bors rollup=never Footnotes |
10127a2
to
ae79c3d
Compare
@spastorino: you've already reviewed the first three commits in #100669, so only the fourth commit needs reviewing. Thanks! |
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
⌛ Trying commit ae79c3d4a81f3afec7ed78e756603011982eda7f with merge 7fa2c81cd586f461cc05f8a9268da92fc3a8c1b0... |
This comment has been minimized.
This comment has been minimized.
☀️ Try build successful - checks-actions |
Queued 7fa2c81cd586f461cc05f8a9268da92fc3a8c1b0 with parent 9c20b2a, future comparison URL. |
Finished benchmarking commit (7fa2c81cd586f461cc05f8a9268da92fc3a8c1b0): comparison url. Instruction count
Max RSS (memory usage)Results
CyclesResults
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. Next Steps: If you can justify the regressions found in this try perf run, please indicate this with @bors rollup=never Footnotes |
ae79c3d
to
abe322d
Compare
@nnethercote r=me after rebasing |
cc9d2d3
to
9bd7058
Compare
I have rebased. Although this is very close to performance-neutral, I will leave it as rollup=never because it has enough of an effect on performance (with improvements and regressions balancing out) that it shouldn't be part of a rollup. @bors r=spastorino |
📌 Commit 9bd705836a272e21e2fbc4e95b5ec39906c9abb0 has been approved by It is now in the queue for this repository. |
☔ The latest upstream changes (presumably #100564) made this pull request unmergeable. Please resolve the merge conflicts. |
In some places we use `Vec<Attribute>` and some places we use `ThinVec<Attribute>` (a.k.a. `AttrVec`). This results in various points where we have to convert between `Vec` and `ThinVec`. This commit changes the places that use `Vec<Attribute>` to use `AttrVec`. A lot of this is mechanical and boring, but there are some interesting parts: - It adds a few new methods to `ThinVec`. - It implements `MapInPlace` for `ThinVec`, and introduces a macro to avoid the repetition of this trait for `Vec`, `SmallVec`, and `ThinVec`. Overall, it makes the code a little nicer, and has little effect on performance. But it is a precursor to removing `rustc_data_structures::thin_vec::ThinVec` and replacing it with `thin_vec::ThinVec`, which is implemented more efficiently.
9bd7058
to
619b8ab
Compare
Rebased. @bors r=spastorino |
☀️ Test successful - checks-actions |
Finished benchmarking commit (3ce46b7): comparison url. Instruction count
Max RSS (memory usage)Results
CyclesResults
If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. Next Steps: If you can justify the regressions found in this perf run, please indicate this with @rustbot label: +perf-regression Footnotes |
As seen above, there are a few small wins and losses here, which balance each other out, and the net effect is perf-neutral. @rustbot label: +perf-regression-triaged |
In some places we use
Vec<Attribute>
and some places we useThinVec<Attribute>
(a.k.a.AttrVec
). This results in various pointswhere we have to convert between
Vec
andThinVec
.This commit changes the places that use
Vec<Attribute>
to useAttrVec
. A lot of this is mechanical and boring, but there aresome interesting parts:
ThinVec
.MapInPlace
forThinVec
, and introduces a macro toavoid the repetition of this trait for
Vec
,SmallVec
, andThinVec
.Overall, it makes the code a little nicer, and has little effect on
performance. But it is a precursor to removing
rustc_data_structures::ThinVec
and replacing it withthin_vec::ThinVec
, which is implemented more efficiently.r? @spastorino