-
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
give the resolver access to TyCtxt #105462
Conversation
This comment was marked as resolved.
This comment was marked as resolved.
This comment has been minimized.
This comment has been minimized.
⌛ Trying commit 9b27fe51e70e1ef01326b1b1ffd1e399f51dea39 with merge 150b43a8f421dbd33945aa017aafcb12a093bbcb... |
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 amazing ❤️
This comment was marked as resolved.
This comment was marked as resolved.
This comment has been minimized.
This comment has been minimized.
This comment was marked as outdated.
This comment was marked as outdated.
50311de
to
dce8058
Compare
This comment was marked as resolved.
This comment was marked as resolved.
This comment has been minimized.
This comment has been minimized.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment has been minimized.
This comment has been minimized.
This comment was marked as outdated.
This comment was marked as outdated.
This comment has been minimized.
This comment has been minimized.
…ation if it fails instead of bubbling out an error
ffd2f51
to
0847b79
Compare
@bors r=cjgillot,petrochenkov |
☀️ Test successful - checks-actions |
Finished benchmarking commit (2deff71): comparison URL. Overall result: ❌ regressions - 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. |
the 2.6% regression (deep-vector opt) is noise (it shows LLVM changes, which this PR can't cause in opt builds). The other regressions are expected due to the additional locking, I am already working on removing some of the locking, but we decided to land this PR regardless as
|
Use a lock-free datastructure for source_span follow up to the perf regression in rust-lang#105462 The main regression is likely the CStore, but let's evaluate the perf impact of this on its own
Note that, compared to instructions, this lead to a much bigger (real) wall-time regression in incremental builds. So you might want to keep an eye on that in PRs that try to recover performance. |
Ah! that's where the failed parallelism for dep-graph loading disappeared to. Will look at wall times in the follow up PRs. |
rustc/rustdoc: Perform name resolver cleanups enabled by #94857 Unblocks rust-lang/rust#105462. r? `@oli-obk`
rustc/rustdoc: Perform name resolver cleanups enabled by #94857 Unblocks rust-lang/rust#105462. r? `@oli-obk`
The resolver is now created after TyCtxt is created. Then macro expansion and name resolution are run and the results fed into queries just like before this PR.
Since the resolver had (before this PR) mutable access to the
CStore
and the source span table, these two datastructures are now behind aRwLock
. To ensure that these are not mutated anymore after the resolver is done, a read lock to them is leaked right after the resolver finishes.PRs split out of this one and leading up to it:
Symbol
for the crate name instead ofString
/str
#105423output_filenames
a real query #106812