-
Notifications
You must be signed in to change notification settings - Fork 14k
Split overlapping_{inherent,trait}_impls #147502
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
This comment was marked as outdated.
This comment was marked as outdated.
|
@bors2 try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
|
@camsteffen: 🔑 Insufficient privileges: not in try users |
|
@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.
Split overlapping_{inherent,trait}_impls
This comment has been minimized.
This comment has been minimized.
|
Finished benchmarking commit (9074fa7): 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 -1.3%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary -3.3%)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: 473.034s -> 471.072s (-0.41%) |
| fn fresh_impl_header<'tcx>( | ||
| infcx: &InferCtxt<'tcx>, | ||
| impl_def_id: DefId, | ||
| is_of_trait: bool, |
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.
Have you perchance tried to pass the impl trait refs through to this function all the way from overlapping_trait_impls? Meaning having a signature of
| is_of_trait: bool, | |
| impl_trait_ref: Option<ty::EarlyBinder<'tcx, ty::TraitRef<'tcx>>>, |
to avoid having to reacquire it down below (thus avoiding the .unwrap()). I'm not asking this from a perf perspective (I presume the green query call overhead is close to negligible) but from a code cleanliness one (tho arguably, my suggestion could be much worse when it comes from to legibility and so on).
If it doesn't inconvenience you too much, could you try that or otherwise assess if that potentially makes things nicer? Idk.
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.
Sure, I think that's a good idea. Even if it's a bit more code. Pushed a commit. Maybe another perf run is in order.
|
Very nice, thanks! I have one question. Once answered, r=me r? fmease @rustbot author |
|
Reminder, once the PR becomes ready for a review, use |
|
@bors delegate+ |
|
✌️ @camsteffen, you can now approve this pull request! If @fmease told you to " |
3592437 to
a1adf25
Compare
This comment has been minimized.
This comment has been minimized.
| impl2_def_id, | ||
| impl1_def_id, | ||
| trait_refs, |
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.
Here the trait refs need to be swapped in accordance with the DefIds above. That's why you see the CI failure.
Maybe instead of passing the two trait refs zipped Option<(_, _)> in a few places, pass them next to the respective DefId. Sth. akin to impl1: (DefId, Option<…>) / (impl1_def_id, impl1_trait_ref): (…, …) or impl1_def_id: DefId, impl1_trait_ref: Option<…>.
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.
I admit this is getting hairier. At any time we can revert back to the bool approach but it might still be interesting to perf the Option<_> approach.
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.
doh! pushed again.
|
@bors r=fmease |
|
@bors ping |
|
😪 I'm awake I'm awake |
|
@bors p=1 (the queue seems stuck) |
|
That didn't help @bors p=0 |
Split overlapping_{inherent,trait}_impls
This yielded some perf improvement for me. Reduces some calls to `impl_trait_header` query. But I think the llvm optimization is more relevant.
|
Ope yes it did |
|
The job Click to see the possible cause of the failure (guessed by this bot) |
|
💔 Test failed - checks-actions |
|
@bors retry |
Split overlapping_{inherent,trait}_impls
This yielded some perf improvement for me. Reduces some calls to `impl_trait_header` query. But I think the llvm optimization is more relevant.
|
@bors retry (bors seems to be stuck) |
|
☀️ Test successful - checks-actions |
What is this?This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.Comparing 3545698 (parent) -> 956f47c (this PR) Test differencesShow 5 test diffsStage 2
Additionally, 4 doctest diffs were found. These are ignored, as they are noisy. Job group index
Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
test-dashboard 956f47c32f1bd97b22cd702d7ccf78f0f0d42c34 --output-dir test-dashboardAnd then open Job duration changes
How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance |
|
Finished benchmarking commit (956f47c): comparison URL. Overall result: ✅ improvements - no action needed@rustbot label: -perf-regression 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.5%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary 3.5%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeResults (secondary 0.0%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Bootstrap: 474.753s -> 474.655s (-0.02%) |
This yielded some perf improvement for me. Reduces some calls to
impl_trait_headerquery. But I think the llvm optimization is more relevant.