T Compiler Meeting Agenda 2025 03 20

T-compiler Meeting Agenda 2025-03-20

Announcements

  • Rust dot release 1.85.1 is out (blog post)
  • @Jieyou Xu suggested looking into two inactive ping groups (icebreakers-llvm and icebreakers-cleanup-crew), maybe they can be removed (Zulip thread)
    • I @apiraino would like like to reactivate the ICE cleanup team, after purging inactive members - it could be a valid support for bisecting ✌️
    • (FIY for the team, feel free to comment)
  • 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

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: 6 months ago)
    • “Add Hotpatch flag” compiler-team#745 (Zulip) (last review activity: 5 months ago)
    • “Add evex512 target feature for AVX10” compiler-team#778 (Zulip) (last review activity: about 0 days ago)
      • Discussed in a design meeting but now it seems that Intel is changing the design of the instruction set (comment)
    • “Policy change around adding new unstable flags” compiler-team#787 (Zulip) (last review activity: 5 months ago)
    • “setup typos check in CI (for rust repo)” compiler-team#817 (Zulip) (last review activity: about 5 days ago)
    • “Rename “dylib” crate type to “rdylib” (keep old name but deprecate it), and maybe do the same for “staticlib” → “cstaticlib”” compiler-team#825 (Zulip) (last review activity: 2 months ago)
    • rustc_target for rust-analyzer” compiler-team#839 (Zulip) (last review activity: about 25 days ago)
    • “Compile UI tests as libraries by default” compiler-team#842 (Zulip) (last review activity: about 12 days ago)
    • “Policy: Require MCP and relevant team nominations for adding (ecosystem, custom codegen backend) testing jobs that would block PR/Merge CI and require documenting failure protocol” compiler-team#845 (Zulip) (last review activity: about 12 days ago)
  • Pending FCP requests (check your boxes!)
    • “sanitizers: Stabilize AddressSanitizer and LeakSanitizer for the Tier 1 targets” rust#123617
    • “Warn about C-style octal literals” rust#131309
    • “Stabilize -Zdwarf-version as -Cdwarf-versionrust#136926
  • Things in FCP (make sure you’re good with it)
  • Accepted MCPs
  • MCPs blocked on unresolved concerns
  • Finalized FCPs (disposition merge)
    • “Add --print host-tuple to print host target tuple” rust#125579
    • “make unsupported_calling_conventions a hard error” rust#129935
    • “Fix ICE when passing DefId-creating args to legacy_const_generics.” rust#130443
    • “Stabilize WebAssembly multivalue, reference-types, and tail-call target features” rust#131080
    • “Lint on combining #[no_mangle] and #[export_name]rust#131558
    • “Reject ?Trait bounds in various places where we unconditionally warned since 1.0” rust#135841
    • “Do not deduplicate list of associated types provided by dyn principal” rust#136458
  • Other teams finalized FCPs
    • “Add lint against function pointer comparisons” rust#118833
    • “Fixup Windows verbatim paths when used with the include! macro” rust#125205
    • “Uplift clippy::double_neg lint as double_negationsrust#126604
    • “Allow dropping dyn Trait principal” rust#126660
    • “atomics: allow atomic and non-atomic reads to race” rust#128778
    • “Lint against getting pointers from immediately dropped temporaries” rust#128985
    • “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 s390x inline assembly” rust#131258
    • “Stabilize Arm64EC inline assembly” rust#131781
    • “Always display first line of impl blocks even when collapsed” rust#132155
    • “rework winnowing to sensibly handle global where-bounds” rust#132325
    • “mark is_val_statically_known intrinsic as stably const-callable” rust#132449
    • “Fix ICE when multiple supertrait substitutions need assoc but only one is provided” rust#133392
    • “[rustdoc] Add sans-serif font setting” rust#133636
    • “disallow repr() on invalid items” rust#133925
    • “Make the wasm_c_abi future compat warning a hard error” rust#133951
    • “fully de-stabilize all custom inner attributes” rust#134276
    • “remove long-deprecated no-op attributes no_start and crate_id” rust#134300
    • “Stabilize feature(trait_upcasting)rust#134367
    • “Fix parsing of ranges after unary operators” rust#134900
    • “Future incompatibility warning unsupported_fn_ptr_calling_conventions: Also warn in dependencies” rust#135767
    • “Reject ?Trait bounds in various places where we unconditionally warned since 1.0” rust#135841
    • “Make cenum_impl_drop_cast a hard error” rust#135964
    • “Allow *const W<dyn A> -> *const dyn A ptr cast” rust#136127
    • “Do not deduplicate list of associated types provided by dyn principal” rust#136458
    • “Do not allow attributes on struct field rest patterns” rust#136490
    • “Make ptr_cast_add_auto_to_object lint into hard error” rust#136764
    • “Turn order dependent trait objects future incompat warning into a hard error” rust#136968
    • “add a “future” edition” rust#137606

Unassigned P-high nightly regressions

  • “iOS binaries crash with latest nightly” rust#138212
    • fixed upstream and will land in the next LLVM 20.1.1 update

Performance logs

triage logs 2025-03-18

A relatively busy week with a large amount of regressions in rollups which made investigations more tricky. Luckily overall the week was an improvement due to some medium sized improvements through improving target feature computation and a type systems internals fix.

Triage done by @rylev. Revision range: 9fb94b32..493c38ba

Summary:

(instructions:u)meanrangecount
Regressions (primary)1.7%[0.2%, 3.0%]18
Regressions (secondary)0.8%[0.2%, 2.7%]37
Improvements (primary)-1.0%[-10.3%, -0.2%]157
Improvements (secondary)-1.7%[-8.8%, -0.2%]158
All (primary)-0.8%[-10.3%, 3.0%]175

5 Regressions, 5 Improvements, 3 Mixed; 5 of them in rollups 44 artifact comparisons made in total

Regressions

Reduce formatting width and precision to 16 bits #136932 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)0.4%[0.4%, 0.5%]3
Regressions (secondary)1.2%[1.2%, 1.2%]1
Improvements (primary)--0
Improvements (secondary)--0
All (primary)0.4%[0.4%, 0.5%]3
  • Not sure the perf regression is necessarily worth investigating - this only impacts exa which I imagine does do quite a bit of formatting. If this were really an issue I’d expect it to show up in more crates given that it impacts the std lib directly.

Remove NtItem and NtStmt #138083 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)2.2%[0.2%, 3.1%]14
Regressions (secondary)0.2%[0.2%, 0.2%]1
Improvements (primary)--0
Improvements (secondary)--0
All (primary)2.2%[0.2%, 3.1%]14
  • Author and reviewer agree to tackle perf once the full refactor is done.

Add a .bss-like scheme for encoded const allocs #137152 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)--0
Regressions (secondary)3.5%[3.2%, 4.1%]3
Improvements (primary)--0
Improvements (secondary)--0
All (primary)--0
  • Author and reviewer agree that the perf tradeoff is worth it.

Rollup of 16 pull requests #138548 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)0.4%[0.2%, 1.0%]8
Regressions (secondary)0.5%[0.2%, 0.9%]14
Improvements (primary)--0
Improvements (secondary)--0
All (primary)0.4%[0.2%, 1.0%]8
  • It’s not clear to me which PR could be the culprit. Instead of wasting a bunch of perf time trying to find out, I think it’s fine if we cut our losses.

Rollup of 7 pull requests #138611 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)0.3%[0.3%, 0.3%]3
Regressions (secondary)--0
Improvements (primary)--0
Improvements (secondary)--0
All (primary)0.3%[0.3%, 0.3%]3
  • The regression is small enough that I don’t think this is really worth looking into.

Improvements

Speed up target feature computation #137586 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)--0
Regressions (secondary)--0
Improvements (primary)-1.3%[-9.9%, -0.2%]55
Improvements (secondary)-1.8%[-8.4%, -0.1%]122
All (primary)-1.3%[-9.9%, -0.2%]55

Add #[define_opaques] attribute and require it for all type-alias-impl-trait sites that register a hidden type #128440 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)--0
Regressions (secondary)--0
Improvements (primary)-0.5%[-1.6%, -0.2%]58
Improvements (secondary)-0.4%[-0.4%, -0.4%]3
All (primary)-0.5%[-1.6%, -0.2%]58

Do not register Self: AutoTrait when confirming auto trait (in old solver) #138249 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)--0
Regressions (secondary)--0
Improvements (primary)-1.8%[-5.2%, -0.2%]21
Improvements (secondary)-1.5%[-4.3%, -0.3%]4
All (primary)-1.8%[-5.2%, -0.2%]21

Rollup of 9 pull requests #138506 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)--0
Regressions (secondary)--0
Improvements (primary)-2.1%[-2.1%, -2.1%]1
Improvements (secondary)-0.3%[-0.3%, -0.3%]1
All (primary)-2.1%[-2.1%, -2.1%]1

Rollup of 7 pull requests #138630 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)--0
Regressions (secondary)--0
Improvements (primary)-0.1%[-0.2%, -0.1%]5
Improvements (secondary)-0.4%[-0.7%, -0.2%]4
All (primary)-0.1%[-0.2%, -0.1%]5

Mixed

Allow bounds checks when enumerating IndexSlice to be elided #137795 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)--0
Regressions (secondary)0.4%[0.4%, 0.4%]6
Improvements (primary)-0.3%[-0.3%, -0.2%]8
Improvements (secondary)--0
All (primary)-0.3%[-0.3%, -0.2%]8

Rollup of 7 pull requests #138414 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)0.4%[0.2%, 1.1%]19
Regressions (secondary)0.6%[0.2%, 1.1%]32
Improvements (primary)-0.2%[-0.2%, -0.2%]2
Improvements (secondary)-0.7%[-1.7%, -0.2%]24
All (primary)0.4%[-0.2%, 1.1%]21
  • #137701 is responsible for the regression. The author and reviewer have been asked for next steps.

Allow more top-down inlining for single-BB callees #138157 (Comparison Link)

(instructions:u)meanrangecount
Regressions (primary)1.0%[0.5%, 1.4%]2
Regressions (secondary)0.3%[0.3%, 0.3%]2
Improvements (primary)-0.7%[-1.1%, -0.4%]5
Improvements (secondary)-0.6%[-0.7%, -0.6%]3
All (primary)-0.2%[-1.1%, 1.4%]7
  • Author notes that the this does regress icount but walltime should be unaffected or even improved.

Nominated Issues

T-compiler

  • “Tracking Issue for perma-unstable wasm-c-abi flag” rust#122532
    • We want to implement breaking ABI changes to WASM (trying to stabilize the ABI and bring some order) but another project (Diplomat, that builds on ICU4X - IIUC) was caught by surprise (comment). We discovered that (as it is to be expected) projects rely on longtime unstable ABIs
    • @RalfJ proposes to emit a Future Compat Warning (#138601) with a blog post and then implement a plan for a migration (comment)
    • More context and a concrete plan proposal laid out by @Alex Crichton at comment. The plan seems to be ok for ICU4X (see comment)
    • T-compiler is asked to discuss and comment (maybe something was overlooked)

RFC

  • No I-compiler-nominated RFCs this time.

Oldest PRs waiting for review

T-compiler

  • “cg_llvm: Reduce the visibility of types, modules and using declarations in rustc_codegen_llvm.” rust#137247 (last review activity: about 23 days ago)
    • cc @Zalathar
  • “not lint break with label and unsafe block” rust#137454 (last review activity: about 23 days ago)
    • cc @Wesley Wiser
  • “pretty-print: Print shebang at the top of the output” rust#137474 (last review activity: about 23 days ago)
    • cc @Esteban Küber
  • “Revise docs for thir::PatKind::ExpandedConstantrust#136612 (last review activity: about 29 days ago)
    • cc @Nadrieril
  • “Pattern Migration 2024: suggest nicer patterns” rust#136496 (last review activity: about 41 days ago)
    • @Nadrieril

Next meetings’ agenda draft: hackmd link