Use &C::Key less in queries.#153464
Conversation
1582c75 to
b491e74
Compare
|
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Use `&C::Key` less in queries.
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (2abf06c): comparison URL. Overall result: ✅ improvements - no action neededBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary 0.4%, secondary 0.6%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 0.4%, secondary 3.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 482.035s -> 481.544s (-0.10%) |
|
r? @JohnTitor rustbot has assigned @JohnTitor. Use Why was this reviewer chosen?The reviewer was selected based on:
|
|
|
This comment has been minimized.
This comment has been minimized.
b491e74 to
1177d0f
Compare
This comment has been minimized.
This comment has been minimized.
|
I rebased. |
This comment has been minimized.
This comment has been minimized.
1177d0f to
5912445
Compare
This comment has been minimized.
This comment has been minimized.
|
I extended this a little, so let's make sure it's still perf-neutral. @bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
Use `&C::Key` less in queries.
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (f47e635): comparison URL. Overall result: ❌ regressions - no action neededBenchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf. @bors rollup=never Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (primary 1.2%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 1.8%, secondary -1.7%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 485.77s -> 479.714s (-1.25%) |
|
Perf-neutral. @bors rollup |
This comment has been minimized.
This comment has been minimized.
|
I wasn't very excited by this as a cleanup, but I guess having And if I guess if perf is neutral there's no particular reason to not pass copyable values by value. r=me after a rebase. |
Currently we use a mix of `C::Key` and `&C::Key` parameters. The former is more common and a bit nicer, so convert some of the latter. This results in less converting between the two types, and fewer sigils.
5912445 to
face186
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
That was the motivation, along with having all the fns in the query vtable be consistent. And then it spread to a bunch of the plumbing/execution/job functions too. |
|
I rebased. @bors r=Zalathar rollup |
Use `&C::Key` less in queries. Currently we use a mix of `C::Key` and `&C::Key` parameters. The former is more common and a bit nicer, so convert some of the latter. This results in less converting between the two types, and fewer sigils.
|
⌛ Testing commit face186 with merge 2754da3... Workflow: https://github.com/rust-lang/rust/actions/runs/22826578734 |
Use `&C::Key` less in queries. Currently we use a mix of `C::Key` and `&C::Key` parameters. The former is more common and a bit nicer, so convert some of the latter. This results in less converting between the two types, and fewer sigils.
|
@bors yield |
|
Auto build was cancelled. Cancelled workflows: The next pull request likely to be tested is #153576. |
…uwer Rollup of 4 pull requests Successful merges: - #153464 (Use `&C::Key` less in queries.) - #153553 (Remove the `rustc_data_structures::assert_matches!` re-exports) - #153561 (Replace the `try_mark_green` hook with direct calls to `tcx.dep_graph`) - #153564 (rendering interpreter OOM as OOM instead of ICE)
Rollup merge of #153464 - nnethercote:less-ref-Key, r=Zalathar Use `&C::Key` less in queries. Currently we use a mix of `C::Key` and `&C::Key` parameters. The former is more common and a bit nicer, so convert some of the latter. This results in less converting between the two types, and fewer sigils.
View all comments
Currently we use a mix of
C::Keyand&C::Keyparameters. The former is more common and a bit nicer, so convert some of the latter. This results in less converting between the two types, and fewer sigils.