Skip to content

Bubble opaque types into aggregates to produce more precise diagnostics on aggregate constructors #95773

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

Closed
wants to merge 4 commits into from

Conversation

oli-obk
Copy link
Contributor

@oli-obk oli-obk commented Apr 7, 2022

Follow up to #95767

This may be a bit overkill, but I'm exploring multiple paths to get the same better diagnostics

r? @ghost

oli-obk added 4 commits April 7, 2022 13:39
…n instead of within the `type_of` query.

This allows us to only store a single hidden type per opaque type instead of having to store one per set of substitutions.
@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label Apr 7, 2022
@oli-obk
Copy link
Contributor Author

oli-obk commented Apr 7, 2022

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Apr 7, 2022
@bors
Copy link
Collaborator

bors commented Apr 7, 2022

⌛ Trying commit cd61e54 with merge fc08ecd2fd1c5224b9078bcff2152d19e82525b2...

@compiler-errors
Copy link
Member

The diagnostic improvements in these UI tests here are great! ✨
love seeing tighter/more descriptive spans on errors.

@bors
Copy link
Collaborator

bors commented Apr 7, 2022

☀️ Try build successful - checks-actions
Build commit: fc08ecd2fd1c5224b9078bcff2152d19e82525b2 (fc08ecd2fd1c5224b9078bcff2152d19e82525b2)

@rust-timer
Copy link
Collaborator

Queued fc08ecd2fd1c5224b9078bcff2152d19e82525b2 with parent fa72316, future comparison URL.

@oli-obk
Copy link
Contributor Author

oli-obk commented Apr 7, 2022

I just realized that deaggregating before borrowck gives us an even better solution without having to make mir building more complex.

I guess i'll start looking into that again xD

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (fc08ecd2fd1c5224b9078bcff2152d19e82525b2): comparison url.

Summary:

  • Primary benchmarks: no relevant changes found
  • Secondary benchmarks: mixed results
Regressions 😿
(primary)
Regressions 😿
(secondary)
Improvements 🎉
(primary)
Improvements 🎉
(secondary)
All 😿 🎉
(primary)
count1 0 3 0 4 0
mean2 N/A 0.3% N/A -0.5% N/A
max N/A 0.4% N/A -0.7% N/A

If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf.

Benchmarking 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 led to changes in compiler perf.

Next Steps: If you can justify the regressions found in this try perf run, please indicate this with @rustbot label: +perf-regression-triaged along with sufficient written justification. If you cannot justify the regressions please fix the regressions and do another perf run. If the next run shows neutral or positive results, the label will be automatically removed.

@bors rollup=never
@rustbot label: +S-waiting-on-review -S-waiting-on-perf +perf-regression

Footnotes

  1. number of relevant changes

  2. the arithmetic mean of the percent change

@rustbot rustbot added perf-regression Performance regression. S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-perf Status: Waiting on a perf run to be completed. labels Apr 7, 2022
@oli-obk
Copy link
Contributor Author

oli-obk commented Apr 28, 2022

Closing this PR, as it's definitely not my preferred route to go about this

@oli-obk oli-obk closed this Apr 28, 2022
@apiraino apiraino removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Apr 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
perf-regression Performance regression. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants