Rollup of 12 pull requests - #163208
Rollup of 12 pull requests#163208
Conversation
Keeping it up-to-date and resolving minor issues with it.
…onsuming it anymore
It's a field that can be used for sorting diagnostics. By default it is set to the primary span. It's only used for `BorrowckDiagnosticsBuffer`. This commit removes it and adds a `sort_span` to each diagnostic recorded in `BorrowckDiagnosticsBuffer`. This avoids various other pieces of code having to deal with it.
Both will be used by the amdgpu target to implement the `gpu-kernel` ABI. `address_space` specifies the address space of an indirect argument. `AmdgpuKernelArg` translates to LLVM’s byref, which is similar to on_stack/byval, however, there is no extra copy made, the pointer may not point to the stack but can point to some other address space, and the passed argument should not be modified. byval and byref are mutually exclusive, so change on_stack to an enum with the new states, Pointer (none), OnStack and AmdgpuKernelArg.
Add support to pass structs, arrays and vectors to amdgpu kernels. Scalars and vectors are taken by value, aggregates are passed by byref pointers. Structs containing a single scalar/vector are handled like a scalar. Judging from clang tests, nvptx seems to do somewhat the same, just using byval instead of byref: https://github.com/llvm/llvm-project/blob/3a8affeef4da19d39191aac316e189eca3214a8c/clang/test/CodeGenCUDA/kernel-args.cu I tested a couple of the lit test signatures on real hardware and it seems to work fine. Given the relatively simple implementation, I hope this amount of testing is enough (the C calling convention seems like a worse fit for Rust’s current ABI code, it’s still giving me headaches).
It's no longer ever used for stashing, so the code looking for it is dead. It became dead in PR 141610 when `generic_arg_infer` was stabilized and `[T; _]` became valid.
Co-authored-by: Boxy <rust@boxyuwu.dev>
Properly implement the gpu-kernel ABI for amdgpu Add support to pass structs, arrays and vectors to amdgpu kernels. Scalars and vectors are taken by value, aggregates are passed by byref pointers. Structs containing a single scalar/vector are handled like a scalar. Judging from clang tests, nvptx seems to do somewhat the same, just using byval instead of byref: https://github.com/llvm/llvm-project/blob/e4e18dba3d77f4a3eea58bcc9ccae5a5498ede7c/clang/test/CodeGenCUDA/kernel-args.cu I tested a couple of the lit test signatures on real hardware and it seems to work fine. Given the relatively simple implementation, I hope this amount of testing is enough (the C calling convention seems like a worse fit for Rust’s current ABI code, it’s still giving me headaches). This adds two members to `PassMode::Indirect`. `address_space` specifies the address space of an on_stack/byval or by_ref pointer argument. `by_ref` translates to LLVM’s byref, which is similar to on_stack/byval, however, there is no extra copy made, the pointer may not point to the stack but can point to some other address space, and the passed argument should not be modified. Both are used by the amdgpu target to implement the `gpu-kernel` ABI. Tracking issue for the `gpu-kernel` ABI: rust-lang#135467 Tracking issue for the amdgpu target: rust-lang#135024
…Titor std: Update `wasip3` crate dependency Keeping it up-to-date and resolving minor issues with it.
Cleanup offload build steps We used to generate a couple of artifacts only because clang offload tooling required them. Now that we fully control the build steps on the Rust side without clang tooling, we can remove most of them. I'll make a follow-up PR afterwards to also remove device.bin artifacts and pass the normal rustc outputs of the device compilation pass. r? oli-obk
…ForArrayLengths, r=BoxyUwU Remove unused `StashKey::UnderscoreForArrayLengths` It's no longer ever used for stashing, so the code looking for it is dead. It became dead in rust-lang#141610 when `generic_arg_infer` was stabilized and `[T; _]` became valid. r? @BoxyUwU
rename direct_const_arg! to gca! Also re-export it from `std`, and make most tests `use std::gca;` rather than writing out `core::` every time the macro is called. Part of the design rework discussed in Zulip [#project-const-generics > talkies at last @ 💬](https://rust-lang.zulipchat.com/#narrow/channel/260443-project-const-generics/topic/talkies.20at.20last/near/620368825) r? @BoxyUwU
…nnethercote Remove `suggestion_for_allocator_api` It's dead code since rust-lang#156882 cc @nia-e
…, r=ShoyuVanilla document `#[rustc_dyn_incompatible_trait]`
…strained-const-args, r=BoxyUwU regression test for unconstrained const args Closes rust-lang#146906
…re-suggestion, r=nnethercote Enhance mutable closure suggestions with as_mut() support This PR changed `can_use_as_ref` to support `as_mut` when `as_ref` is not proper.
Fix Typo in `std::sys::process::unix::unsupported::wait_status` Docs Noticed while collecting data on conditional compilation for potential aliasing (see [Zulip](https://rust-lang.zulipchat.com/#narrow/channel/219381-t-libs/topic/Using.20.60build.2Ers.60.20for.20cfg.20aliases.20in.20.60std.60/with/625458363) for details) that this attribute was missing its closing brace. Extremely trivial, might as well fix it!
…, r=lqd Remove `DiagInner::sort_span` It's a field that can be used for sorting diagnostics. By default it is set to the primary span. It's only used for `BorrowckDiagnosticsBuffer`. This commit removes it and adds a `sort_span` to each diagnostic recorded in `BorrowckDiagnosticsBuffer`. This avoids various other pieces of code having to deal with it. r? @lqd
…bit, r=tgross35 Fix flt2dec build on 16-bit targets Closes rust-lang#163158. Fixes build breakage rust-lang#162879 on the two 16-bit targets, `avr-none` and `msp430-none-elf`, by including `target_pointer_width = "16"` in all the cfg attributes for the u32 implementations for bignum and flt2dec.
This comment has been minimized.
This comment has been minimized.
Rollup of 12 pull requests try-job: dist-various-1 try-job: test-various try-job: test-x86_64-gnu-aux try-job: test-x86_64-gnu-llvm-21-3 try-job: test-x86_64-msvc-1 try-job: test-aarch64-apple-1 try-job: test-aarch64-apple-2 try-job: test-x86_64-mingw-1 try-job: test-i686-msvc try-job: test-armhf-gnu
This comment has been minimized.
This comment has been minimized.
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 9a9d194 (parent) -> a92214c (this PR) Test differencesShow 98 test diffsStage 1
Stage 2
Additionally, 26 doctest diffs were found. These are ignored, as they are noisy. Job group index
Test dashboardRun cargo run --manifest-path src/ci/citool/Cargo.toml -- \
test-dashboard a92214c92df8cc0261f5ab5c08c6376c2c03a958 --output-dir test-dashboardAnd then open Job duration changes
How to interpret the job duration changes?Job durations can vary a lot, based on the actual runner instance |
|
Finished benchmarking commit (a92214c): comparison URL. Overall result: ❌ regressions - no action needed@rustbot label: -perf-regression Instruction countOur most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.
Max RSS (memory usage)Results (secondary 0.9%)A less reliable metric. May be of interest, but not used to determine the overall result above.
CyclesResults (secondary -1.2%)A less reliable metric. May be of interest, but not used to determine the overall result above.
Binary sizeThis perf run didn't have relevant results for this metric. Bootstrap: 489.957s -> 501.272s (2.31%) |
|
📌 Perf builds for each rolled up PR:
parent commit: 9a9d1946d1 In the case of a perf regression, run the following command with the SHAs of each PR you suspect might be the cause: |
|
@rust-timer triage all |
Running triage with 1 benchmarkTriage only executes the benchmarks on rollup members, that were changed significantly on the rollup.
#162177 2eefc87 Properly implement the gpu-kernel ABI for amdgpuThis perf run didn't have relevant results for the `instruction count` metric.Instruction countThis perf run didn't have relevant results for this metric. Max RSS (memory usage)This perf run didn't have relevant results for this metric. CyclesThis perf run didn't have relevant results for this metric. Binary sizeThis perf run didn't have relevant results for this metric. #163168 8421ad3 std: Update
|
| mean | range | count | |
|---|---|---|---|
| Regressions ❌ (primary) |
- | - | 0 |
| Regressions ❌ (secondary) |
- | - | 0 |
| Improvements ✅ (primary) |
- | - | 0 |
| Improvements ✅ (secondary) |
-1.4% | [-1.4%, -1.4%] | 1 |
| All ❌✅ (primary) | - | - | 0 |
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#163198 c5e0813 rename direct_const_arg! to gca!
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.8% | [0.7%, 0.9%] | 3 |
| Improvements ✅ (primary) |
- | - | 0 |
| Improvements ✅ (secondary) |
- | - | 0 |
| All ❌✅ (primary) | - | - | 0 |
Max RSS (memory usage)
This perf run didn't have relevant results for this metric.
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#163205 cad1e1b Remove suggestion_for_allocator_api
This perf run didn't have relevant results for the `instruction count` metric.
Instruction count
This perf run didn't have relevant results for this metric.
Max RSS (memory usage)
Results (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) |
- | - | 0 |
| Regressions ❌ (secondary) |
- | - | 0 |
| Improvements ✅ (primary) |
- | - | 0 |
| Improvements ✅ (secondary) |
-2.6% | [-2.6%, -2.6%] | 1 |
| All ❌✅ (primary) | - | - | 0 |
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#162497 9cfd87e document #[rustc_dyn_incompatible_trait]
This perf run didn't have relevant results for the `instruction count` metric.
Instruction count
This perf run didn't have relevant results for this metric.
Max RSS (memory usage)
Results (secondary -4.3%)
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) |
-4.3% | [-4.3%, -4.3%] | 1 |
| All ❌✅ (primary) | - | - | 0 |
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#162702 9fba0a8 regression test for unconstrained const args
This perf run didn't have relevant results for the `instruction count` metric.
Instruction count
This perf run didn't have relevant results for this metric.
Max RSS (memory usage)
This perf run didn't have relevant results for this metric.
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#163191 2901913 Enhance mutable closure suggestions with as_mut() support
This perf run didn't have relevant results for the `instruction count` metric.
Instruction count
This perf run didn't have relevant results for this metric.
Max RSS (memory usage)
This perf run didn't have relevant results for this metric.
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#163192 4fe9beb Fix Typo in std::sys::process::unix::unsupported::wait_status Docs
This perf run didn't have relevant results for the `instruction count` metric.
Instruction count
This perf run didn't have relevant results for this metric.
Max RSS (memory usage)
This perf run didn't have relevant results for this metric.
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#163196 bfe5389 Remove DiagInner::sort_span
This perf run didn't have relevant results for the `instruction count` metric.
Instruction count
This perf run didn't have relevant results for this metric.
Max RSS (memory usage)
Results (secondary -1.5%)
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) |
-1.5% | [-1.5%, -1.5%] | 1 |
| All ❌✅ (primary) | - | - | 0 |
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
#163197 f447349 Fix flt2dec build on 16-bit targets
This perf run didn't have relevant results for the `instruction count` metric.
Instruction count
This perf run didn't have relevant results for this metric.
Max RSS (memory usage)
This perf run didn't have relevant results for this metric.
Cycles
This perf run didn't have relevant results for this metric.
Binary size
This perf run didn't have relevant results for this metric.
Successful merges:
wasip3crate dependency #163168 (std: Updatewasip3crate dependency)StashKey::UnderscoreForArrayLengths#163194 (Remove unusedStashKey::UnderscoreForArrayLengths)suggestion_for_allocator_api#163205 (Removesuggestion_for_allocator_api)#[rustc_dyn_incompatible_trait]#162497 (document#[rustc_dyn_incompatible_trait])std::sys::process::unix::unsupported::wait_statusDocs #163192 (Fix Typo instd::sys::process::unix::unsupported::wait_statusDocs)DiagInner::sort_span#163196 (RemoveDiagInner::sort_span)r? @ghost
Create a similar rollup