T-compiler Meeting Agenda 2021-12-09
Announcements
- Reminder: if you see a PR/issue that seems like there might be legal implications due to copyright/IP/etc, please let the Core team know (or at least message @pnkfelix or @Wesley Wiser so we can pass it along).
MCPs/FCPs
- New MCPs (take a look, see if you like them!)
- “Tier 3 target proposal: riscv64gc-linux-android (Android target for
riscv64gc
)” compiler-team#472 - “
-Dwarnings
to cover all warnings” compiler-team#473
- “Tier 3 target proposal: riscv64gc-linux-android (Android target for
- Old MCPs (not seconded, take a look)
- “CI should exercise (subset of) tests under –stage 1” compiler-team#439 (last review activity: 3 months ago)
- “Accept
pc
in place ofunknown
andunknown
in place ofpc
forx86_64
andi?86
targets” compiler-team#441 (last review activity: 5 months ago) - “Make
-Z binary-dep-depinfo
the default behavior” compiler-team#464 (last review activity: 2 months ago)
- Pending FCP requests (check your boxes!)
- “Tracking issue for RFC 2115: In-band lifetime bindings” rust#44524
- Things in FCP (make sure you’re good with it)
- No FCP requests this time.
- Accepted MCPs
- “Unstable lints should be considered unknown” compiler-team#469
- Finalized FCPs (disposition merge)
- “Tracking Issue for cargo report future-incompat” rust#71249
- “Tracking Issue for inline assembly (
asm!
)” rust#72016
WG checkins
@WG-mir-optimization checkin by @oli (previous checkin)
- @Dylan MacKenzie (ecstatic-morse) is working on the MIR pass manager #91386
- there is a lot of unclarity around what dialects of MIR we have and what rules exist
- Not really a new thing, but it caused a bug (#90762) and almost caused a much bigger bug (in #73255), though we that caught that in time
- See this discussion for some examples of the problems
@WG-polymorphization checkin by @davidtwco (previous checkin)
we’re making slow progress, @lcnr is working on a patch that removes our main blocker, there’s not much else to do with polymorphization until that’s complete.
Backport nominations
T-compiler stable / T-compiler beta
- :beta: “Sync portable-simd to remove autosplats” rust#91484
- @simulacrum suggests two strategies for backport: either backported in full or a targeted backport that excludes the submodule with a config setting (see comment)
- No stable nominations for
T-compiler
this time.
T-rustdoc stable / T-rustdoc beta
- :beta: “Make rustdoc headings black, and markdown blue” rust#91534
- seems all fine to backport this small UI fix
- No stable nominations for
T-rustdoc
this time.
:back: / :shrug: / :hand:
PRs S-waiting-on-team
- “Make specifying repr optional for fieldless enums” rust#88203
- waiting on
T-lang
- waiting on
- “Make feature key optional for rustc_stable, rustc_const_stable attributes” rust#88588
- Waiting on
T-libs
- Waiting on
- “remove pref_align_of intrinsic” rust#90877
- Waiting on
T-lang
- Waiting on
Oldest PRs waiting for review
- Introduce linter for diagnostic messages (last activity: about 30 days ago)
- previously reviewed by @Esteban Küber and @simulacrum
- (tests are failing after upstream changes)
- “Abort in panic_abort eh_personality” rust#86801 (last review activity: 4 months ago)
- mentioned in T-compiler meeting about some time ago, no new activity
- no reviewer assigned: who could own this PR?
- “Fix ICE with inferred type in
const
orstatic
item” rust#89161 (last review activity: about 57 days ago)- last review from Niko
- improve type abiguity error for functions and methods (last activity about 1 month ago)
- PR author @lcnr
- previously reviewed by @Esteban Küber
- PR seems to need another round of review
- Introduce MIR summary to avoid loading large bodies without inlining them (last activity about 1 month ago)
- PR author @cjgillot
- last review from @wesley wiser
- perf. bench report large regression
Issues of Note
Short Summary
- 3 T-compiler P-critical issues
- 77 T-compiler P-high issues
- 1 P-critical, 2 P-high, 0 P-medium, 0 P-low regression-from-stable-to-beta
- 0 P-critical, 3 P-high, 1 P-medium, 1 P-low regression-from-stable-to-nightly
- 2 P-critical, 49 P-high, 81 P-medium, 12 P-low regression-from-stable-to-stable
P-critical
-
“Miscompilation where binding only some fields leaks the others” rust#90752
- Fixed in rust#90788 (stable 1.58)
-
“Huge compile-time regression in beta/nightly” rust#91128
- issue author mentions that disabling the new LLVM pass manager makes the regression disappear
- some public code to reproduce is at this comment
- @nikic followed up with some great insights
- discussed last week, linked to PR #91190, due to be evaluated again next week
-
“Compile-time regression between 1.56.1 and 1.57.0 for deeply nested decorator types” rust#91598
- this affects production code on different scenarios
- time needed for compilation seems to have abnormally regressed
-
No
P-critical
issues forT-rustdoc
this time.
P-high regressions
- “Where bounds with associated types equality cause overflow.” rust#89503
Unassigned P-high nightly regressions
- “Undefined reference to
getauxval
in functioninit_have_lse_atomics
when compiling to nightlyaarch64-unknown-linux-musl
” rust#89626 - “nightly-2021-12-02 to nightly-2021-12-03 regression (PR #91354): auto-deref on
Cow
does not seem to work anymore in all circumstances” rust#91489
Performance logs
A week of mostly rather small changes with many regressions being hard to diagnose. The largest regression comes from the introduction of a new future (desugaring .await
into a call to IntoFuture::into_future
). This was deemed acceptable as it only seems to have a negative impact in stress test situations where async/await is used more than one would normally expect. Unfortunately this does mean regressions beat out improvements this week.
Triage done by @rylev. Revision range: 1c0287830e0fb3c4007afea2819ba03766da6e9c..ecb65b0e170fc5275870c9d0fba7267a57cf35e5
3 Regressions, 5 Improvements, 5 Mixed; 3 of them in rollups, 29 Untriaged Pull Requests 31 comparisons made in total
Regressions
Implement version of normalize_erasing_regions that allows for normalization failure #91255
- Small regression in instruction counts (up to 0.9% on
incr-full
builds ofctfe-stress-4
) - Nothing immediately jumps out as an issue, so a run of cachegrind might be necessary.
- Left a comment as such.
Rollup of 10 pull requests #91486
- Large regression in instruction counts (up to 1.1% on
full
builds ofmatch-stress-enum
) - Seems to be impacting compilation of match expressions, but none of the sub PRs seem to be a likely culprit.
- Left a comment as such.
Reintroduce into_future
in .await
desugaring #90737
- Very large regression in instruction counts (up to 9.3% on
incr-full
builds ofdeeply-nested-async
) - The regression was very much expected but only really appears in extremely
await
-heavy code. We’ll have to wait to see how this impacts real world users, and see if we can work on performance of trait obligation resolution to improve the performance lost. - A more detailed justification for taking the performance hit can be found here.
Improvements
- Lint elided lifetimes in path during lifetime resolution. #90446
- Optimize
rustc_lexer
#91393 - Revert “Auto merge of #91354 - fee1-dead:const_env, r=spastorino” #91491
- Add a MIR pass manager (Taylor’s Version) #91475
Mixed
Introduce RawVec::reserve_for_push
. #91352
- Large improvement in instruction counts (up to -3.0% on
incr-patched: println
builds ofwebrender-wrench
) - Small regression in instruction counts (up to 0.4% on
incr-patched: println
builds ofstyle-servo
) - The improvements outweigh the regressions and are mostly found in real-world crates.
- Justification for the regressions can be found here.
Rollup of 4 pull requests #91406
- Large improvement in instruction counts (up to -2.7% on
incr-unchanged
builds ofdeeply-nested-async
) - Very large regression in instruction counts (up to 7.1% on
incr-unchanged
builds ofclap-rs
) - A case where it’s hard to tell where the regression is coming from, but it is a quite a large regression in a real-world crate (albeit one that is a tiny bit noisy).
- Both and only really touch rustdoc so that’s unlikely the culprit.
- Left a comment for follow up
Cleanup: Eliminate ConstnessAnd #91354
- Small improvement in instruction counts (up to -0.6% on
full
builds ofdeeply-nested
) - Moderate regression in instruction counts (up to 1.1% on
incr-patched: b9b3e592dd cherry picked
builds ofstyle-servo
) - Reverted by #91491 which recovered the regression.
Rollup of 4 iffy pull requests #91455
- Very large improvement in instruction counts (up to -6.7% on
incr-unchanged
builds ofclap-rs
) - Large regression in instruction counts (up to 3.4% on
incr-unchanged
builds ofclap-rs
) - The improvements outweigh the regressions with the largest regression in a non-noisy benchmark being only 0.8%.
- Given the difficult nature of figuring out what caused regressions in a rollup of 4 iffy pull requests, we’ll let this one slide.
Reduce boilerplate around infallible folders #91318
- Moderate improvement in instruction counts (up to -0.8% on
incr-unchanged
builds ofexterns
) - Small regression in instruction counts (up to 0.6% on
full
builds ofdeeply-nested
) - cachegrind was already run, but there are no clear explanations for the regressions.
Nominated Issues
- No
I-compiler-nominated
issues t this time.
- No nominated RFCs for
T-compiler
this time.