-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
rustdoc: Collect "rustdoc-reachable" items during early doc link resolution #107054
Conversation
r? @jsha (rustbot has picked a reviewer for you, use r? to override) |
This implementation is preliminary and needs perf-tuning and cleanup. |
This comment has been minimized.
This comment has been minimized.
⌛ Trying commit dc7c5a6bdb60e23019a5fcc27cd43010b84bdfa6 with merge 5c2a19ad7168382f8bbb7a16230e73c294255bd7... |
This comment has been minimized.
This comment has been minimized.
☀️ Try build successful - checks-actions |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (5c2a19ad7168382f8bbb7a16230e73c294255bd7): comparison URL. Overall result: ❌ regressions - ACTION NEEDEDBenchmarking 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 Instruction countThis is a highly reliable metric that was used to determine the overall result at the top of this comment.
Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
|
dc7c5a6
to
a791adf
Compare
To retrieve these flags rustdoc currently has to mass decode full attributes for items in the whole crate tree, so it's better to pre-compute it in advance. This is especially for short-term performance of rust-lang#107054 because resolver cannot use memoization of query results yet.
This comment was marked as resolved.
This comment was marked as resolved.
rustc_metadata: Encode `doc(hidden)` flag to metadata To retrieve these flags rustdoc currently has to mass decode full attributes for items in the whole crate tree, so it's better to pre-compute it in advance. This is especially important for short-term performance of rust-lang#107054 because resolver cannot use memoization of query results yet.
a791adf
to
24de73e
Compare
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
⌛ Trying commit 3982258 with merge 65af9c7fb16aacb9bffc7f415bc387d8740839c2... |
☀️ Try build successful - checks-actions |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (65af9c7fb16aacb9bffc7f415bc387d8740839c2): comparison URL. Overall result: ✅ improvements - no action neededBenchmarking 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 Instruction countThis is a highly reliable metric that was used to determine the overall result at the top of this comment.
Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesThis benchmark run did not return any relevant results for this metric. |
@rustbot ready |
Thanks! @bors r+ rollup=never |
☀️ Test successful - checks-actions |
Finished benchmarking commit (6874f4e): comparison URL. Overall result: ❌✅ regressions and improvements - ACTION NEEDEDNext Steps: If you can justify the regressions found in this perf run, please indicate this with @rustbot label: +perf-regression Instruction countThis is a highly reliable metric that was used to determine the overall result at the top of this comment.
Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesThis benchmark run did not return any relevant results for this metric. |
Perf wins greatly outweigh the regressions here. @rustbot label: +perf-regression-triaged |
This pass only needs to know about visibilities, attributes and reexports, so it can be run early, similarly to
compute_effective_visibilities
in rustc.Results of this pass can be used to prune the list of extern impls early thus improving performance of #94857.