-
Notifications
You must be signed in to change notification settings - Fork 13.8k
eagerly compute sub_unification_table
again
#140375
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
cb71df2
to
a0fef49
Compare
This comment has been minimized.
This comment has been minimized.
a0fef49
to
46487b0
Compare
This comment has been minimized.
This comment has been minimized.
46487b0
to
54a32a1
Compare
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
eagerly compute `sub_relations` again We still only using them for diagnostics with the old solver. We could use them for cycle detection in generalization and it seems desirable to do so in the future. However, this is unsound with the old trait solver as its cache does not track these `sub_relations` in any way. We would also need to consider them when canonicalizing as otherwise instantiating the canonical response may fail. Necessary for type inference guidance due to not-yet defined opaque types, cc rust-lang/trait-system-refactor-initiative#182. r? `@compiler-errors`
611d7ae
to
26f4ee0
Compare
This comment has been minimized.
This comment has been minimized.
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
eagerly compute `sub_relations` again We still only using them for diagnostics with the old solver. We could use them for cycle detection in generalization and it seems desirable to do so in the future. However, this is unsound with the old trait solver as its cache does not track these `sub_relations` in any way. We would also need to consider them when canonicalizing as otherwise instantiating the canonical response may fail. Necessary for type inference guidance due to not-yet defined opaque types, cc rust-lang/trait-system-refactor-initiative#182. r? `@compiler-errors`
☀️ Try build successful - checks-actions |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (e184142): comparison URL. Overall result: ❌ regressions - please read the text belowBenchmarking 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 the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.
Max RSS (memory usage)Results (primary -0.6%, secondary -4.5%)This 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.
CyclesResults (primary 0.0%, secondary -1.6%)This 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.
Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 765.701s -> 765.069s (-0.08%) |
26f4ee0
to
c629527
Compare
This comment has been minimized.
This comment has been minimized.
☔ The latest upstream changes (presumably #140474) made this pull request unmergeable. Please resolve the merge conflicts. |
see perf run in #140480 (comment) |
comparing these two perf runs, tracking sub_relations in canonical inputs does slightly worsen performance: https://perf.rust-lang.org/compare.html?start=e1841428183d264d2f48328b3de5c0f25654315a&end=9613271ee15ea18ed41f396fc7aaf4c1f760410a&stat=instructions%3Au |
@rustbot ready |
sub_relations
againsub_unification_table
again
1262693
to
ad169c9
Compare
ad169c9
to
b51a3a5
Compare
This PR was rebased onto a different master 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. |
☀️ 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 a78f9aa (parent) -> 9c27f27 (this PR) Test differencesShow 20 test diffsStage 1
Stage 2
Additionally, 18 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 9c27f27ea3bab79a2fec827ef3ae0009959d60f4 --output-dir test-dashboard And 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 (9c27f27): comparison URL. Overall result: ❌✅ regressions and improvements - please read the text belowOur benchmarks found a performance regression caused by this PR. Next Steps:
@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.3%, secondary -0.9%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (primary -3.0%, secondary -1.5%)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: 466.425s -> 467.433s (0.22%) |
Unfortunately an expected perf regression, spent a while trying to reduce the impact. Necessary for the new solver |
Marking as triaged. @rustbot label: +perf-regression-triaged |
Previously called
sub_relations
. We still only using them for diagnostics right now. This mostly reverts #119989. Necessary for type inference guidance due to not-yet defined opaque types, cc rust-lang/trait-system-refactor-initiative#182.We could use them for cycle detection in generalization and it seems desirable to do so in the future. However, this is unsound with the old trait solver as its cache does not track these
sub_unification_table
in any way.We now properly track the
sub_unification_table
when canonicalizing so using them in the new solver is totally sound and the performance impact is far more manageable than I thought back in #119989.r? @compiler-errors