-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Simplify caching and storage for queries #101307
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
Conversation
817974b
to
1b32d61
Compare
@bors try @rust-timer queue |
Awaiting bors try build completion. @rustbot label: +S-waiting-on-perf |
⌛ Trying commit 1b32d6190360f1e2e0a199705ce352d4bb34767d with merge b8b3b08be266b740bb07752f836e0adbb20f5243... |
☀️ Try build successful - checks-actions |
Queued b8b3b08be266b740bb07752f836e0adbb20f5243 with parent e4f0493, future comparison URL. |
Finished benchmarking commit (b8b3b08be266b740bb07752f836e0adbb20f5243): comparison URL. Overall result: ❌✅ regressions and improvements - 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.
CyclesThis benchmark run did not return any relevant results for this metric. Footnotes |
The single large regression is in llvm, and there are many smaller improvements. I think this is just a change in codegen units that will go away on any further small change. |
3608906
to
0339a00
Compare
This comment has been minimized.
This comment has been minimized.
468f1ec
to
69ce855
Compare
☔ The latest upstream changes (presumably #101303) made this pull request unmergeable. Please resolve the merge conflicts. |
In practice, it was only ever used with `ArenaCacheSelector`. Change it to a single boolean `arena_cache` rather than allowing queries to specify an arbitrary type.
This uses exactly the same types for query results as `typeck`, which doesn't have custom code. It's not clear to me why this code exists (it goes back even before queries used a proc macro), but it compiles fine without the custom loader. Remove it for simplicity.
Instead, define a single function, parameterized only by the return type.
This is not only simpler, but removes a generic function and unwrap. I have hope it will see compile time and bootstrap time improvements.
We want to refer to `crate::plumbing::try_load_from_disk` in the const, but hard-coding it in rustc_queries, where we don't yet know the crate this macro will be called in, seems kind of hacky. Do it in query_impl instead.
41dd7bf
to
0a9d7db
Compare
@bors r+ |
☀️ Test successful - checks-actions |
Finished benchmarking commit (a5b58ad): 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. Footnotes |
The @rustbot label: +perf-regression-triaged |
I highly recommend reviewing commit-by-commit; each individual commit is quite small but it can be hard to see looking at the overall diff that the behavior is the same. Each commit depends on the previous.
r? @cjgillot