T Compiler Meeting Agenda 2024 10 31

T-compiler Meeting Agenda 2024-10-31

Announcements

  • Reminder: if you see a PR/issue that seems like there might be legal implications due to copyright/IP/etc, please let us know (or at least message @davidtwco or @Wesley Wiser so we can pass it along).

Other WG meetings

  • None

MCPs/FCPs

  • New MCPs (take a look, see if you like them!)
  • Old MCPs (stale MCP might be closed as per MCP procedure)
    • None at this time
  • Old MCPs (not seconded, take a look)
    • “Add hygiene attributes to compile expanded source code” compiler-team#692 (Zulip) (last review activity: about 41 days ago)
    • “Add Hotpatch flag” compiler-team#745 (Zulip) (last review activity: about 20 days ago)
    • “Add evex512 target feature for AVX10” compiler-team#778 (Zulip) (last review activity: about 55 days ago)
    • “Make the test cfg a userspace check-cfg” compiler-team#785 (Zulip) (last review activity: about 6 days ago)
    • “Policy change around adding new unstable flags” compiler-team#787 (Zulip) (last review activity: about 13 days ago)
    • “Normalize FileCheck directives” compiler-team#789 (Zulip) (last review activity: about 13 days ago)
    • “Relink, don’t rebuild” compiler-team#790 (Zulip) (last review activity: about 13 days ago)
    • “Support for a new wasm32-linux-musl Tier-3 target” compiler-team#797 (Zulip) (last review activity: about 13 days ago)
  • Pending FCP requests (check your boxes!)
    • “sanitizers: Stabilize AddressSanitizer and LeakSanitizer for the Tier 1 targets” rust#123617
    • “Stabilize WebAssembly multivalue, reference-types, and tail-call target features” rust#131080
    • “Lint on combining #[no_mangle] and #[export_name]rust#131558
  • Things in FCP (make sure you’re good with it)
    • “Fix ICE when passing DefId-creating args to legacy_const_generics.” rust#130443
    • “Reject raw lifetime followed by ', like regular lifetimes do” rust#132341
  • Accepted MCPs
  • MCPs blocked on unresolved concerns
  • Finalized FCPs (disposition merge)
    • “Add --print host-tuple to print host target tuple” rust#125579
    • “Do not consider match/let/ref of place that evaluates to ! to diverge, disallow coercions from them too” rust#129392
    • “make unsupported_calling_conventions a hard error” rust#129935
    • “Check elaborated projections from dyn don’t mention unconstrained late bound lifetimes” rust#130367
  • Other teams finalized FCPs
    • “Add lint against function pointer comparisons” rust#118833
    • “Fixup Windows verbatim paths when used with the include! macro” rust#125205
    • “Allow dropping dyn Trait principal” rust#126660
    • “Lint against &T to &mut T and &T to &UnsafeCell<T> transmutes” rust#128351
    • “atomics: allow atomic and non-atomic reads to race” rust#128778
    • “Lint against getting pointers from immediately dropped temporaries” rust#128985
    • “Decide on name for derive(SmartPtr)rust#129104
    • “Do not consider match/let/ref of place that evaluates to ! to diverge, disallow coercions from them too” rust#129392
    • “Make deprecated_cfg_attr_crate_type_name a hard error” rust#129670
    • “Stabilize expr_2021 fragment specifier in all editions” rust#129972
    • “Check elaborated projections from dyn don’t mention unconstrained late bound lifetimes” rust#130367
    • “Finish stabilization of result_ffi_guaranteesrust#130628
    • “Stabilize const ptr::write* and mem::replacerust#130954
    • “Stabilize shorter_tail_lifetimerust#131445

Backport nominations

T-compiler beta / T-compiler stable

  • :beta: “Reject raw lifetime followed by ', like regular lifetimes do” rust#132341
    • Authored and nominated by compiler-errors
    • Also nominated for (and approved by) T-lang (comment) as this is a new syntax.
  • :beta: “Mark simplify_aggregate_to_copy mir-opt as unsound” rust#132356
    • Authored by jieyouxu
    • Fixes a P-critical miscompile (rust#132353) caused by recent changes in MIR optimizations
    • Note: partially reverts e7386b3, the mir-opt implementation is just marked as unsound but not reverted to make reland reviews easier. This PR partially reverts commit e7386b3, reversing changes made to 02b1be1. The mir-opt implementation is just marked as unsound but not reverted to make reland reviews easier. Test changes are reverted if they were not pure additions. Tests added by the original PR received -Z unsound-mir-opts compile-flags.
  • No stable nominations for T-compiler this time.

T-types stable / T-types beta

  • No beta nominations for T-types this time.
  • No stable nominations for T-types this time.

PRs S-waiting-on-team

T-compiler

Issues of Note

Short Summary

P-critical

T-compiler

  • “[Regression] LLVM asserts “conflicting locations for variable” since 1.82” rust#131944
    • In Fedora 39 builds (with its LLVM 17), rustc hits a libstdc++ assertion via LLVM on all Tier 1 targets
    • Bisected to #128861, seems to be handled in #132010 (correct @cuviper?)
  • “Panic in nightly 1.83.0 and 1.84.0 with opt-level >= 1 when unwrapping Some variant” rust#132353
    • Solved by #132356 (thanks @Jieyou Xu)

T-types

  • No P-critical issues for T-types 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 for 2024-10-29

This week saw a lot of activity both on the regressions and improvements side. There was one large regression, which was immediately reverted. Overall, the week ended up being positive, thanks to a rollup PR that caused a tiny improvement to almost all benchmarks.

Triage done by @kobzol. Revision range: 3e33bda0..c8a8c820

Summary:

(instructions:u) mean range count
Regressions (primary) 0.7% [0.2%, 2.7%] 15
Regressions (secondary) 0.8% [0.1%, 1.6%] 22
Improvements (primary) -0.6% [-1.5%, -0.2%] 153
Improvements (secondary) -0.7% [-1.9%, -0.1%] 80
All (primary) -0.5% [-1.5%, 2.7%] 168

6 Regressions, 6 Improvements, 4 Mixed; 6 of them in rollups 58 artifact comparisons made in total

Regressions

Revise arm platform notes regarding soft float #130987 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 2.9% [2.9%, 2.9%] 1
Regressions (secondary) - - 0
Improvements (primary) - - 0
Improvements (secondary) - - 0
All (primary) 2.9% [2.9%, 2.9%] 1
  • Noise, this PR only modified documentation.
  • Marked as triaged.

Dont consider predicates that may hold as impossible in is_impossible_associated_item #131840 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 0.6% [0.2%, 2.3%] 9
Regressions (secondary) 0.2% [0.2%, 0.2%] 1
Improvements (primary) - - 0
Improvements (secondary) - - 0
All (primary) 0.6% [0.2%, 2.3%] 9
  • The largest regression was just noise, the rest was small enough and was deemed to be acceptable.
  • Marked as triaged.

nightly feature tracking: get rid of the per-feature bool fields #132027 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 1.2% [1.1%, 1.2%] 4
Regressions (secondary) 0.5% [0.1%, 1.1%] 34
Improvements (primary) - - 0
Improvements (secondary) - - 0
All (primary) 1.2% [1.1%, 1.2%] 4
  • The small regressions were only on tiny benchmarks and stress tests, which was deemed to be acceptable.

Rollup of 10 pull requests #132094 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 0.2% [0.1%, 0.2%] 4
Regressions (secondary) - - 0
Improvements (primary) - - 0
Improvements (secondary) - - 0
All (primary) 0.2% [0.1%, 0.2%] 4
  • The tiny regressions were reverted in a follow-up merge.
  • Marked as triaged.

Emit future-incompatibility lint when calling/declaring functions with vectors that require missing target feature #127731 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 5.0% [0.3%, 16.9%] 77
Regressions (secondary) 4.7% [0.1%, 29.4%] 30
Improvements (primary) -0.1% [-0.1%, -0.1%] 1
Improvements (secondary) - - 0
All (primary) 4.9% [-0.1%, 16.9%] 78

bump stdarch #132145 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 0.9% [0.9%, 0.9%] 1
Regressions (secondary) - - 0
Improvements (primary) - - 0
Improvements (secondary) - - 0
All (primary) 0.9% [0.9%, 0.9%] 1
  • One tiny regression caused by a dependency upgrade, no need to investigate further.
  • Marked as triaged.

Improvements

(ci) Update macOS Xcode to 15 #131570 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) - - 0
Regressions (secondary) - - 0
Improvements (primary) -3.6% [-3.6%, -3.6%] 1
Improvements (secondary) - - 0
All (primary) -3.6% [-3.6%, -3.6%] 1

better default capacity for str::replace #131929 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) - - 0
Regressions (secondary) - - 0
Improvements (primary) -0.3% [-0.4%, -0.2%] 3
Improvements (secondary) - - 0
All (primary) -0.3% [-0.4%, -0.2%] 3

rustdoc: hash assets at rustdoc build time #131951 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) - - 0
Regressions (secondary) - - 0
Improvements (primary) -0.2% [-0.3%, -0.1%] 6
Improvements (secondary) -0.3% [-0.3%, -0.1%] 17
All (primary) -0.2% [-0.3%, -0.1%] 6

Revert #127731 “Emit error when calling/declaring functions with unavailable …” #132152 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) - - 0
Regressions (secondary) 0.3% [0.3%, 0.3%] 1
Improvements (primary) -4.7% [-14.4%, -0.3%] 75
Improvements (secondary) -4.5% [-22.7%, -0.2%] 27
All (primary) -4.7% [-14.4%, -0.3%] 75
  • Revert of the previously mentioned #127731.

Rollup of 3 pull requests #132171 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) - - 0
Regressions (secondary) - - 0
Improvements (primary) -0.3% [-0.3%, -0.2%] 2
Improvements (secondary) -0.3% [-0.4%, -0.2%] 16
All (primary) -0.3% [-0.3%, -0.2%] 2
  • The small wins probably come from #132168.

Rollup of 9 pull requests #132277 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) - - 0
Regressions (secondary) - - 0
Improvements (primary) -0.5% [-1.7%, -0.1%] 186
Improvements (secondary) -0.6% [-1.7%, -0.1%] 92
All (primary) -0.5% [-1.7%, -0.1%] 186
  • The large amount of small wins might have been caused by #130259.

Mixed

Rollup of 5 pull requests #132053 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 1.0% [0.3%, 1.8%] 2
Regressions (secondary) - - 0
Improvements (primary) - - 0
Improvements (secondary) -0.5% [-0.5%, -0.5%] 1
All (primary) 1.0% [0.3%, 1.8%] 2
  • Large number of small-ish regressions that were just under the statistical threshold.
  • Might have been caused by LLVM doing more work because of #132031.
  • Not marking as triaged yet, investigation ongoing.

Represent trait constness as a distinct predicate #131985 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 0.5% [0.1%, 1.2%] 16
Regressions (secondary) 0.9% [0.1%, 1.5%] 22
Improvements (primary) -0.3% [-0.5%, -0.1%] 44
Improvements (secondary) -0.3% [-0.6%, -0.1%] 13
All (primary) -0.1% [-0.5%, 1.2%] 60
  • This was a large internal refactoring that had mostly positive or neutral effects on performance, although it did cause regressions in doc builds on several benchmarks.
  • It was deemed acceptable during review.
  • Marked as triaged.

Rollup of 4 pull requests #132116 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 0.3% [0.1%, 1.8%] 49
Regressions (secondary) 0.8% [0.1%, 1.3%] 6
Improvements (primary) -0.3% [-0.3%, -0.3%] 1
Improvements (secondary) -0.7% [-1.8%, -0.1%] 3
All (primary) 0.3% [-0.3%, 1.8%] 50
  • The regression was caused by #131983, which stabilized a new behavior change that will appear in Edition 2024.
  • Not marking as triaged yet, there might be a way to claw some of the regressions back.

Rollup of 12 pull requests #132317 (Comparison Link)

(instructions:u) mean range count
Regressions (primary) 0.2% [0.2%, 0.4%] 4
Regressions (secondary) 0.2% [0.2%, 0.2%] 1
Improvements (primary) -0.2% [-0.4%, -0.1%] 6
Improvements (secondary) -0.3% [-0.3%, -0.3%] 1
All (primary) -0.0% [-0.4%, 0.4%] 10
  • Performance results were a wash.
  • Marked as triaged.

Nominated Issues

T-compiler

  • “Update bundled musl to 1.2.5” rust#125692
    • FIY for everyone - IIUC already approved by @Wesley Wiser at Eurorust
    • The update will require many crates to update to a libc released one year ago (comment)
    • Why the update would be nice explained in #130920
    • Also Zulip discussion

RFC

  • No I-compiler-nominated RFCs this time.

Oldest PRs waiting for review

T-compiler

  • “add error message for c# style named arguments” rust#118733 (last review activity: 10 months ago)
    • cc: @Esteban Küber
  • “Silence errors in expressions caused by bare traits in paths in 2021 edition” rust#125784 (last review activity: 4 months ago)
    • cc: @León Orell Liehr (fmease) but also author cc @Esteban Küber - pretty big diff, needs a rebase. Unsure about the best way to proceed
  • “Mangle rustc_std_internal_symbols functions” rust#127173 (last review activity: 4 months ago)
    • cc @fee1-dead
  • “Support target-spec json file extension in various cases” rust#127389 (last review activity: 3 months ago)
    • cc @Wesley Wiser (by reading the comments, PR needs wider agreement, at least a discussion)
  • “collect doc alias as tips during resolution” rust#127721 (last review activity: 3 months ago)
    • cc @Esteban Küber

Next meetings' agenda draft: hackmd link