T Compiler Meeting Agenda 2022 01 20

T-compiler Meeting Agenda 2022-01-20

Tracking Issue

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).
  • New template for rustc targets (see rust#90498), new targets should use this to document their requirements.

MCPs/FCPs

  • New MCPs (take a look, see if you like them!)
  • Old MCPs (not seconded, take a look)
    • “Accept pc in place of unknown and unknown in place of pc for x86_64 and i?86 targets” compiler-team#441 (last review activity: 6 months ago)
    • “Make -Z binary-dep-depinfo the default behavior” compiler-team#464 (last review activity: 3 months ago)
    • “Tier 3 target proposal: riscv64gc-linux-android (Android target for riscv64gc)” compiler-team#472 (last review activity: about 41 days ago)
    • -Dwarnings to cover all warnings” compiler-team#473 (last review activity: about 41 days ago)
    • “Build-time execution sandboxing” compiler-team#475 (last review activity: about 23 days ago)
  • Pending FCP requests (check your boxes!)
    • No pending FCP requests this time.
  • Things in FCP (make sure you’re good with it)
    • “CI should exercise (subset of) tests under –stage 1” compiler-team#439
    • “Adding known bugs to test cases” compiler-team#476
    • “Introduce a new linter for diagnostic meesages” compiler-team#478
    • “Change location of where clause on GATs” rust#90076
    • “Stabilize -Z instrument-coverage as -C instrument-coveragerust#90132
    • “Stabilize -Z print-link-args as --print link-argsrust#91606
  • Accepted MCPs
    • No new accepted proposals this time.
  • Finalized FCPs (disposition merge)
    • No new finished FCP (disposition merge) this time.

WG checkins

@_WG-mir-opt by @oli (previous checkin)

  • We may finally have a fix for the early_otherwise_branch mir optimization. [rust#91840]
  • We now have much better infrastructure for ordering and managing all our mir opts [rust#91475]

@WG-polymorphization checkin by @davidtwco (previous checkin)

from @lcnr: wg-polymorphization isn’t doing too much rn, I am still - since 2 updates ago iirc - working on a change which should fix the remaining blocker to reenable it and have to fix some last remaining issues, and then do a lot of perf work. I think that rust#89514 is the last polymorphization pr that’s gotten merged

Backport nominations

T-compiler stable / T-compiler beta

  • :beta: “Revert “Do not hash leading zero bytes of i64 numbers in Sip128 hasher”” rust#93014
    • PR reverts 92103
    • not yet merged
    • reviewer @The 8472|330154 nominated for backport
    • mentions that perf regressions are expected and triaged (see comment) and that should a fairly low impact backport
  • No stable nominations for T-compiler this time.

T-rustdoc stable / T-rustdoc beta

  • :beta: “Fix rust logo style” rust#92764
    • a nice fix for the Rust logo when setting a dark theme
  • :beta: “rustdoc: fix intra-link for generic trait impls” rust#92792
    • fixes rust#92662 a P-high regression that breaks compiling documentation
    • no concerns, seems fine for backport
  • No stable nominations for T-rustdoc this time.

:back: / :shrug: / :hand:

PRs S-waiting-on-team

T-compiler

  • “Stabilize -Z print-link-args as --print link-argsrust#91606
    • Entered last week in final-comment-period
    • Can S-waiting-on-team label be removed now?

Oldest PRs waiting for review

T-compiler

  • “Automatically implement AsRepr and allow deriving FromRepr for fieldless enums” rust#81642 (last review activity: 3 months ago)
    • assigned to @estebank
  • “Support #[global_allocator] without the allocator shim” rust#86844 (last review activity: 2 months ago)
    • @pnkfelix self-assigned
  • “make memcmp return a value of c_int_width instead of i32” rust#90791 (last activity: 24 days ago)
    • assigned to @joshtriplett
  • “Fix variant index / discriminant confusion in uninhabited enum branching” rust#89764 (last review activity: 2 months ago)
    • assigned to @wesley wiser, also reviewed from @RalfJ
  • “remove some indirection from proc_macro_server” rust#90876 (last review activity: 2 months ago)
    • assigned to @oli
    • perf improvements are the goal for this PR, results are mixed, is the author waiting for a feedback?

Issues of Note

Short Summary

P-critical

T-compiler

T-rustdoc

  • No P-critical issues for T-rustdoc this time.

P-high regressions

P-high beta regressions

  • No P-high beta regressions this time.

Unassigned P-high nightly regressions

  • No unassigned P-high nightly regressions this time.

Performance logs

triage logs

Quiet week for regular rustc performance; incremental builds (particularly ones with little recompilation to do) saw an average 1.5% improvement. rustdoc also saw several notable optimizations land which improve performance, particularly on larger benchmarks.

Triage done by @simulacrum. Revision range: 72e74d7b9cf1a7901650227e74650f1fcc797600..7bc7be860f99f4a40d45b0f74e2d01b02e072357

3 Regressions, 5 Improvements, 2 Mixed; 2 of them in rollups 30 comparisons made in total

Regressions

Rollup of 9 pull requests #92844

  • Very large regression in instruction counts (up to 8.2% on full builds of keccak check)
  • Unknown cause, though suspected to be #92006. This may also be due to sensitivity in keccak and similar benchmarks to a particularly hot loop in the compiler, which sometimes is less nicely compiled by LLVM. (See #92816 (comment) for details).

Add {Add,Sub,Mul,Div,Rem,BitXor,BitOr,BitAnd}{,Assign}<$t> to Saturat… #92356

  • Large regression in instruction counts (up to 2.8% on full builds of helloworld doc)
  • Expected regression in documentation builds; there’s just more to document.

Rollup of 10 pull requests #92970

  • Moderate regression in instruction counts (up to 0.9% on incr-unchanged builds of externs opt)
  • Unclear cause, but regression is relatively small and limited to just one benchmark.

Improvements

  • Migrate rustdoc from Tera to Askama #92526
  • Very large improvement in instruction counts (up to -30.7% on full builds of externs doc)
    • Major improvement in instruction counts for rustdoc; a less significant win on wall time for most benchmarks, though particularly heavy ones (e.g., stm32f4) do see a sizeable improvement of around 10% less wall time.
  • Introduce new TaskDepsRef enum to track allow/ignore/forbid status #92681
  • rustdoc: avoid many Symbol to String conversions. #91948
  • Optimize impl_read_unsigned_leb128 #92604
  • Reduce use of LocalDefId <-> HirId maps #90146
  • rustc_metadata: Switch all decoder methods from vectors to iterators #92245

Mixed

partially revertish lazily "compute" anon const default substs #92805

  • Moderate improvement in instruction counts (up to -1.4% on full builds of deeply-nested-async check)
  • Small regression in instruction counts (up to 0.9% on incr-unchanged builds of clap-rs check)

Remove deprecated LLVM-style inline assembly #92816

  • Very large improvement in instruction counts (up to -7.5% on full builds of keccak check)
  • Moderate regression in instruction counts (up to 1.0% on incr-unchanged builds of ctfe-stress-4 check)

Nominated Issues

T-compiler

  • No nominated issues for T-compiler this time.

RFC

  • No nominated RFCs for T-compiler this time.