Skip to content

Rollup of 8 pull requests #142589

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

Merged
merged 16 commits into from
Jun 16, 2025
Merged

Rollup of 8 pull requests #142589

merged 16 commits into from
Jun 16, 2025

Conversation

Kobzol
Copy link
Contributor

@Kobzol Kobzol commented Jun 16, 2025

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

folkertdev and others added 16 commits June 12, 2025 15:10
In particular, anything that includes `none` in the target tripple, and `nvptx64-nvidia-cuda`
It currently has two, which don't accurately capture what's happening --
the `TupleStruct` spans are allocated in `ResolverArenas`, which is
different to where the `Expr` is allocated -- and require some
"outlives" constraints to be used.

This commit adds another lifetime, renames the existing ones, and
removes the "outlives" constraints.
Pick up the following pull requests:

* ci: remove binary size check (not relevant in rust-lang/rust)
  <rust-lang/backtrace-rs#710>
* Upgrade `ruzstd`, `object`, and `addr2line` to the latest versions
  <rust-lang/backtrace-rs#718>
…=workingjubilee

Fix RISC-V C function ABI when passing/returning structs containing floats

RISC-V passes structs containing only one or two floats (or a float and integer pair) in registers, as long as the individual floats/integers fit in a single corresponding register (see [the ABI specification](https://github.com/riscv-non-isa/riscv-elf-psabi-doc/releases/download/v1.0/riscv-abi.pdf) for details). Before this PR, Rust would not check what offset the second float/integer was at, instead assuming that it was at the standard offset for its default alignment. However, as the offset can be affected by `#[repr(align(N))]` and `#[repr(packed)]`, this caused miscompilations (see rust-lang#115609). To fix this, this PR introduces a `rest_offset` field to `CastTarget` that can be used to explicitly specify at what offset the `rest` part of the cast is located at.

While fixing this, I discovered another bug: the size of the cast target was being used as the size of the MIR return place (when the function was using a `PassMode::Cast` return type). However, the cast target is allowed to be smaller than the size of the actual type, causing a miscompilation. This PR fixes this issue by using the largest of the size of the type and the size of the cast target as the size of the MIR return place, ensuring all reads/writes will be inbounds.

Fixes the RISC-V part of rust-lang#115609.

cc target maintainers of `riscv64gc-unknown-linux-gnu`: `@kito-cheng` `@michaelmaitland` `@robin-randhawa-sifive` `@topperc`

r? `@workingjubilee`
Don't suggest converting `///` to `//` when expecting `,`

Fixes rust-lang#142311
…ieyouxu

ignore `run-make` tests that need `std` on targets without `std`

In particular, anything that includes `none` in the target triple, and `nvptx64-nvidia-cuda`. Right now we don't cross-compile the `run-make` tests, but we want to in the future.

This uses `//@ needs-target-std` introduced in rust-lang#142297.

Useful for rust-lang#139244 and rust-lang#141856.

The modified files are based on running rust-lang#141856 locally. It might be that rust-lang#139244 uncovers some additional files, but that PR needs to be rebased (though actually I'd advice to rebase the non-test changes onto this PR, probably faster that way).

r? ``@jieyouxu``

<details>
  <summary>vim notes for future me</summary>

Make a file with lines like this

```
/home/folkertdev/rust/rust/tests/run-make/export/disambiguator/rmake.rs:1:1
/home/folkertdev/rust/rust/tests/run-make/invalid-so/rmake.rs:1:1
/home/folkertdev/rust/rust/tests/run-make/no-builtins-attribute/rmake.rs:1:1
/home/folkertdev/rust/rust/tests/run-make/export/extern-opt/rmake.rs:1:1
/home/folkertdev/rust/rust/tests/run-make/link-dedup/rmake.rs:1:1
```

then

```
:set errorformat=%f:%l:%c
:cfile /tmp/files-to-fix.txt
```
```
:copen
:cnext
:cprev
```

are your friends

</details>
…onszelmann

Port `#[rustc_as_ptr]` to the new attribute system

It might make sense to introduce some new parser analogous to `Single`, but even more simple: for parsing attributes that take no arguments and may appear only once (such as `#[rustc_as_ptr]` or `#[rustc_const_stable_indirect]`). Not sure if this should be a single `impl` parsing all such attributes, or one impl per attribute. Or how it will play along with the upcoming rework of attribute validation. Or how these argumentless attributes should be called (I've loosely referred to them as `markers` in the name of the new module in this PR, but not sure how good it is).

This is a part of rust-lang#131229, so
r? `@jdonszelmann`

---

For reference, the `#[rustc_as_ptr]` attribute was created back in rust-lang#132732 as a followup to rust-lang#128985.
…es, r=petrochenkov

Fix `PathSource` lifetimes.

It currently has two, which don't accurately capture what's happening -- the `TupleStruct` spans are allocated in `ResolverArenas`, which is different to where the `Expr` is allocated -- and require some "outlives" constraints to be used.

This commit adds another lifetime, renames the existing ones, and removes the "outlives" constraints.

r? `@petrochenkov`
…ngjubilee

Update the `backtrace` submodule

Pick up the following pull requests:

* ci: remove binary size check (not relevant in rust-lang/rust) <rust-lang/backtrace-rs#710>
* Upgrade `ruzstd`, `object`, and `addr2line` to the latest versions <rust-lang/backtrace-rs#718>
…st, r=RalfJung

Test naked asm for wasm32-unknown-unknown

cc rust-lang#133952 (comment)
`fn candidate_is_applicable` to method

r? `@BoxyUwU`
@rustbot rustbot added A-attributes Area: Attributes (`#[…]`, `#![…]`) A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-run-make Area: port run-make Makefiles to rmake.rs S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Jun 16, 2025
@Kobzol
Copy link
Contributor Author

Kobzol commented Jun 16, 2025

@bors r+ rollup=never p=5

@bors
Copy link
Collaborator

bors commented Jun 16, 2025

📌 Commit b1ba2cd has been approved by Kobzol

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 16, 2025
@bors
Copy link
Collaborator

bors commented Jun 16, 2025

⌛ Testing commit b1ba2cd with merge 45acf54...

@bors bors mentioned this pull request Jun 16, 2025
@bors
Copy link
Collaborator

bors commented Jun 16, 2025

☀️ Test successful - checks-actions
Approved by: Kobzol
Pushing 45acf54 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jun 16, 2025
@bors bors merged commit 45acf54 into rust-lang:master Jun 16, 2025
11 checks passed
@rustbot rustbot added this to the 1.89.0 milestone Jun 16, 2025
@rust-timer
Copy link
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#139340 Fix RISC-V C function ABI when passing/returning structs co… d92f475dc4777f06c9bf78ba60370b7ed144c32c (link)
#142341 Don't suggest converting /// to // when expecting , 77a04fc58d23a2af032c85f2ac19d973c345818f (link)
#142414 ignore run-make tests that need std on targets without … 5478f5ad3a43896c57ad3383eb11c98ca839d283 (link)
#142498 Port #[rustc_as_ptr] to the new attribute system 890932634b5405456e51fd605f799da7f5d9e38a (link)
#142554 Fix PathSource lifetimes. a3d18350a3eae577af9e343f3f2f4e57cdc13da5 (link)
#142562 Update the backtrace submodule 9a203014469487c086e58fdc50ddda329d054da2 (link)
#142565 Test naked asm for wasm32-unknown-unknown c4b11c7c3cd898ad6d63b08831a50fe01808ff48 (link)
#142573 fn candidate_is_applicable to method cf73d03afc59d768e50d23087455568e2b0135da (link)

previous master: 3bc767e1a2

In the case of a perf regression, run the following command for each PR you suspect might be the cause: @rust-timer build $SHA

Copy link
Contributor

What is this? This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.

Comparing 3bc767e (parent) -> 45acf54 (this PR)

Test differences

Show 128 test diffs

Stage 1

  • [assembly] tests/assembly/naked-functions/wasm32.rs#wasm32-unknown: [missing] -> pass (J1)
  • [codegen] tests/codegen/riscv-abi/cast-local-large-enough.rs: [missing] -> pass (J1)
  • [ui] tests/ui/abi/numbers-arithmetic/float-struct.rs: [missing] -> pass (J1)
  • [ui] tests/ui/parser/doc-comment-after-missing-comma-issue-142311.rs: [missing] -> pass (J1)

Stage 2

  • [run-make] tests/run-make/allow-warnings-cmdline-stability: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/artifact-incr-cache: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/artifact-incr-cache-no-obj: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/bin-emit-no-symbols: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/box-struct-no-segfault: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/checksum-freshness: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/compiler-lookup-paths-2: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/crate-circular-deps-link: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/cross-lang-lto: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/cross-lang-lto-upstream-rlibs: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/dep-info: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/doctests-merge: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/doctests-runtool: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/dump-mono-stats: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/duplicate-output-flavors: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/embed-metadata: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/embed-source-dwarf: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/emit-named-files: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/emit-path-unhashed: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/emit-to-stdout: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/env-dep-info: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/error-found-staticlib-instead-crate: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/export/disambiguator: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/export/extern-opt: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/export/simple: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/extern-diff-internal-name: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/extern-flag-rename-transitive: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/extern-multiple-copies: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/extern-multiple-copies2: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/ice-static-mir: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/include-all-symbols-linking: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/include-bytes-deps: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/incremental-debugger-visualizer: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/inline-always-many-cgu: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/invalid-so: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/invalid-symlink-search-path: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/invalid-tmpdir-env-var: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/issue-107495-archive-permissions: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/issue-125484-used-dependencies: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/json-error-no-offset: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/lib-trait-for-trait-no-ice: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/link-arg: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/link-args-order: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/link-dedup: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/linker-warning: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/llvm-outputs: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/lto-avoid-object-duplication: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/manual-crate-name: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/many-crates-but-no-match: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/metadata-only-crate-no-ice: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/missing-crate-dependency: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/multiple-emits: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/native-lib-alt-naming: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/native-link-modifier-verbatim-linker: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/native-link-modifier-verbatim-rustc: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/no-builtins-attribute: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/no-builtins-lto: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/non-unicode-env: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/non-unicode-in-incremental-dir: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/optimization-remarks-dir: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/overwrite-input: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/parallel-rustc-no-overwrite: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/pass-linker-flags: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/pass-linker-flags-from-dep: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/pgo-gen-no-imp-symbols: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/pretty-print-with-dep-file: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/proc-macro-three-crates: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/remap-path-prefix-dwarf: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/repr128-dwarf: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/reproducible-build-2: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/rlib-format-packed-bundled-libs-2: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/rustc-macro-dep-files: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/rustdoc-scrape-examples-invalid-expr: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/rustdoc-scrape-examples-multiple: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/rustdoc-scrape-examples-ordering: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/rustdoc-scrape-examples-remap: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/rustdoc-scrape-examples-test: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/rustdoc-scrape-examples-whitespace: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/short-ice: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/stable-symbol-names: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/staticlib-blank-lib: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/staticlib-broken-bitcode: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/staticlib-thin-archive: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/stdin-rustc: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/symbol-visibility: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/symbols-include-type-name: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/track-path-dep-info: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/type-mismatch-same-crate-name: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/unknown-mod-stdin: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/unstable-feature-usage-metrics: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/unstable-feature-usage-metrics-incremental: pass -> ignore (ignored if target does not support std) (J0)
  • [run-make] tests/run-make/use-suggestions-rust-2018: pass -> ignore (ignored if target does not support std) (J0)
  • [ui] tests/ui/abi/numbers-arithmetic/float-struct.rs: [missing] -> pass (J2)
  • [ui] tests/ui/parser/doc-comment-after-missing-comma-issue-142311.rs: [missing] -> pass (J2)
  • [assembly] tests/assembly/naked-functions/wasm32.rs#wasm32-unknown: [missing] -> pass (J3)
  • [codegen] tests/codegen/riscv-abi/cast-local-large-enough.rs: [missing] -> pass (J3)

(and 18 additional test diffs)

Additionally, 10 doctest diffs were found. These are ignored, as they are noisy.

Job group index

Test dashboard

Run

cargo run --manifest-path src/ci/citool/Cargo.toml -- \
    test-dashboard 45acf54eea118ed27927282b5e0bfdcd80b7987c --output-dir test-dashboard

And then open test-dashboard/index.html in your browser to see an overview of all executed tests.

Job duration changes

  1. x86_64-apple-2: 5270.7s -> 6380.3s (21.1%)
  2. x86_64-apple-1: 9137.0s -> 10577.7s (15.8%)
  3. dist-x86_64-apple: 8632.2s -> 7363.1s (-14.7%)
  4. dist-aarch64-apple: 7398.0s -> 6402.5s (-13.5%)
  5. dist-apple-various: 8854.6s -> 8256.2s (-6.8%)
  6. x86_64-gnu-llvm-19-2: 5973.5s -> 5592.0s (-6.4%)
  7. dist-loongarch64-linux: 6276.8s -> 5934.5s (-5.5%)
  8. x86_64-gnu-llvm-19-1: 3646.7s -> 3452.9s (-5.3%)
  9. dist-arm-linux-gnueabi: 4907.2s -> 4674.4s (-4.7%)
  10. x86_64-gnu-nopt: 7371.8s -> 7721.5s (4.7%)
How to interpret the job duration changes?

Job durations can vary a lot, based on the actual runner instance
that executed the job, system noise, invalidated caches, etc. The table above is provided
mostly for t-infra members, for simpler debugging of potential CI slow-downs.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (45acf54): comparison URL.

Overall result: ✅ improvements - no action needed

@rustbot label: -perf-regression

Instruction count

Our most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-1.2% [-1.2%, -1.2%] 1
Improvements ✅
(secondary)
-1.2% [-1.2%, -1.2%] 1
All ❌✅ (primary) -1.2% [-1.2%, -1.2%] 1

Max RSS (memory usage)

Results (primary 1.9%, secondary -2.6%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
6.4% [6.4%, 6.4%] 1
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-2.6% [-2.6%, -2.6%] 1
Improvements ✅
(secondary)
-2.6% [-2.6%, -2.6%] 1
All ❌✅ (primary) 1.9% [-2.6%, 6.4%] 2

Cycles

This benchmark run did not return any relevant results for this metric.

Binary size

Results (secondary -0.0%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-0.0% [-0.0%, -0.0%] 1
All ❌✅ (primary) - - 0

Bootstrap: 757.216s -> 756.938s (-0.04%)
Artifact size: 372.11 MiB -> 372.14 MiB (0.01%)

@Kobzol Kobzol deleted the rollup-j90fk2j branch June 17, 2025 05:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-attributes Area: Attributes (`#[…]`, `#![…]`) A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-run-make Area: port run-make Makefiles to rmake.rs merged-by-bors This PR was explicitly merged by bors. rollup A PR which is a rollup S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.