-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
rustdoc: use the next solver for blanket impl synthesis #125907
base: master
Are you sure you want to change the base?
Conversation
@bors try @rust-timer queue |
This comment was marked as resolved.
This comment was marked as resolved.
I guess I'll also do a crater run 🤔? I don't want to accidentally make rustdoc hang or ice for half the ecosystem. |
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
Let's try again. Bors, please respond this time around! @bors try @rust-timer queue |
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
@bors try |
…t, r=<try> rustdoc: use the next solver for blanket impl synthesis Furthermore use an `ObligationCtxt` instead of operating on an `InferCtxt` directly and don't drop the obligations generated by the type relating (fixes a FIXME). Originally I just wanted to submit the infcx→ocx change. However, that regressed `tests/rustdoc-ui/ice-blanket-impl-52873.rs` (pass→overflow error) because with `ocx.select_where_possible` we would no longer suppress / defatalize (canonical) overflow errors on the last obligation we register. CC rust-lang#54199 which introduced that special case. Obviously in the next solver overflows are non-fatal incl. `ice-blanket-impl-52873.rs`. Hence the switch now. Note that I wanted to hold off on switching to the new solver since it makes rust-lang#114891 go from long I-compiletime to I-compilemem + I-hang + eventual death by the OOM killer. So I don't know maybe we should block this PR on me finding a rustc reproducer for the rustdoc issue rust-lang#114891 (this is on my agenda) to be able to properly investigate the underlying next-solver issue.
☀️ Try build successful - checks-actions |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (dcbecf2): comparison URL. Overall result: ❌ regressions - 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)Results (primary 23.3%, secondary 5.2%)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 824.6%, secondary 7.0%)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: 667.872s -> 669.107s (0.18%) |
okay lol, that is crazy |
…ket-impls, r=GuillaumeGomez rustdoc: add a regression test for a former blanket impl synthesis ICE Fixes rust-lang#119792 (also passes in rust-lang#125907 in case you were wondering). r? rustdoc
…ket-impls, r=GuillaumeGomez rustdoc: add a regression test for a former blanket impl synthesis ICE Fixes rust-lang#119792 (also passes in rust-lang#125907 in case you were wondering). r? rustdoc
…ket-impls, r=GuillaumeGomez rustdoc: add a regression test for a former blanket impl synthesis ICE Fixes rust-lang#119792 (also passes in rust-lang#125907 in case you were wondering). r? rustdoc
…ket-impls, r=GuillaumeGomez rustdoc: add a regression test for a former blanket impl synthesis ICE Fixes rust-lang#119792 (also passes in rust-lang#125907 in case you were wondering). r? rustdoc
…ket-impls, r=GuillaumeGomez rustdoc: add a regression test for a former blanket impl synthesis ICE Fixes rust-lang#119792 (also passes in rust-lang#125907 in case you were wondering). r? rustdoc
This comment has been minimized.
This comment has been minimized.
18b8f6b
to
e1e3180
Compare
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
…t, r=<try> rustdoc: use the next solver for blanket impl synthesis Furthermore use an `ObligationCtxt` instead of operating on an `InferCtxt` directly and don't drop the obligations generated by the type relating. Originally I just wanted to submit the infcx→ocx change. However, that regressed `tests/rustdoc-ui/ice-blanket-impl-52873.rs` (pass→overflow error) because with `ocx.select_where_possible` we would no longer suppress / defatalize (canonical) overflow errors. CC rust-lang#54199 which introduced that special case. Obviously in the next solver overflows are non-fatal incl. `ice-blanket-impl-52873.rs`. Hence the switch now. ~~Note that I wanted to hold off on switching to the new solver since it makes rust-lang#114891 go from long I-compiletime to I-compilemem + I-hang + eventual death by the OOM killer. So I don't know maybe we should block this PR on me finding a rustc reproducer for the rustdoc issue rust-lang#114891 (this is on my agenda) to be able to properly investigate the underlying next-solver issue.~~ Fixes rust-lang#114891.
☀️ Try build successful - checks-actions |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (c9f5be2): comparison URL. Overall result: ❌ regressions - 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)Results (primary 4.9%)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 11.2%, secondary 4.3%)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: 751.515s -> 752.426s (0.12%) |
That's quite a big regression. Do you have ideas on how to limit it or is it not possible for the moment? |
the following PRs will likely reduce the perf impact here: |
we still haven't optimized the new solver at all really apart from making sure the architecture itself is able to be performant, so there are still a lot of low-hanging fruits in the new solver. |
Thanks for the information! Don't hesitate if there is anything I can help with. |
e1e3180
to
c32dd09
Compare
@bors try @rust-timer queue |
This comment has been minimized.
This comment has been minimized.
…t, r=<try> rustdoc: use the next solver for blanket impl synthesis Presumably due to better caching behavior, switching from the old to the next solver *drastically* improves the compile time on certain inputs. See rust-lang#114891. Fixes rust-lang#114891. Furthermore use an `ObligationCtxt` instead of operating on an `InferCtxt` directly and don't drop the obligations generated by the type relating. For context, originally I just wanted to submit the infcx→ocx change. However, that regressed `tests/rustdoc-ui/ice-blanket-impl-52873.rs` (pass→overflow error) because with `ocx.select_where_possible` we would no longer suppress / defatalize (canonical) overflow errors. CC rust-lang#54199 which introduced that special case. Obviously in the next solver overflows are non-fatal incl. `ice-blanket-impl-52873.rs`. Hence the switch now. https://github.com/rust-lang/rust/labels/S-blocked on perf improvements for the next solver.
☀️ Try build successful - checks-actions |
This comment has been minimized.
This comment has been minimized.
Finished benchmarking commit (9daeecb): comparison URL. Overall result: ❌✅ regressions and improvements - 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 5.1%, secondary -2.3%)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 9.6%, secondary 4.7%)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: 780.385s -> 781.632s (0.16%) |
Presumably due to better caching behavior, switching from the old to the next solver drastically improves the compile time on certain inputs. See #114891.
Fixes #114891.
Furthermore use an
ObligationCtxt
instead of operating on anInferCtxt
directly and don't drop the obligations generated by the type relating.For context, originally I just wanted to submit the infcx→ocx change. However, that regressed
tests/rustdoc-ui/ice-blanket-impl-52873.rs
(pass→overflow error) because withocx.select_where_possible
we would no longer suppress / defatalize (canonical) overflow errors. CC #54199 which introduced that special case. Obviously in the next solver overflows are non-fatal incl.ice-blanket-impl-52873.rs
. Hence the switch now.S-blockedStatus: Marked as blocked ❌ on something else such as an RFC or other implementation work.
on perf improvements for the next solver.