Skip to content

Rollup of 10 pull requests - #162918

Closed
JonathanBrouwer wants to merge 39 commits into
rust-lang:mainfrom
JonathanBrouwer:rollup-sJ7H4ui
Closed

JonathanBrouwer wants to merge 39 commits into
rust-lang:mainfrom
JonathanBrouwer:rollup-sJ7H4ui

Conversation

@JonathanBrouwer

Copy link
Copy Markdown
Member

Successful merges:

r? @ghost

Create a similar rollup

TechnoPorg and others added 30 commits September 9, 2026 15:36
LLVM 24 has moved from TargetOptions::ThreadModel to specifying
thread-model as a module flag. This catches us up.
This copy will retain and is specialized for blocking operations.
Incr comp only uses the non-blocking variant.
This lock registry allows emulating fd based locks (like flock()) on top
of the fcntl(F_SETLK) process based locks, thereby ensuring that
concurrent rustc instances inside the same process don't break the incr
comp locking scheme.
Borrow checking produces some weird, spanless help messages about fixing
lifetime errors. If there are multiple, they are grouped under a header
like this:
```
help: the following changes may resolve your lifetime errors
```
There are three forms of these. One of the forms is this:
```
  = help: add bound `'a: 'b`
```
This form is redundant, because there is always an earlier help note (on
a proper error message with a span) like this:
```
  = help: consider adding the following bound: `'b: 'a`
```

This commit removes these redundant messages.
…ostic

It's currently a spanless top-level help diagnostic. This commit changes
it to an error (with one or more help subdiagnostics), gives it a span,
and changes the wording.

Note that giving it a span means that deduplication will no longer
erroneously hide diagnostics with identical wording from different
functions! Because of this, several "duplicate diagnostic" mentions are
removed from the expected outputs.

It's still a weird diagnostic (and now counts towards the error count)
but it's better than before.

This also removes the one use of buffered non-error diagnostics. So
`BufferedDiag` is also removed.
And remove `struct_help`, to discourage use of `Level::Help`.
(`Sublevel::Help` is fine.)
If `fmaf16` is exported, the existing version hits errors like:

    error: `compiler_builtins` cannot call functions through upstream monomorphizations; encountered invalid call from `core::fmt::num::<impl core::fmt::Debug for u64>::fmt` to `core::fmt::num::imp::<impl core::fmt::Display for u64>::fmt`
       --> library/core/src/fmt/num.rs:85:17
        |
     79 | / macro_rules! impl_Debug {
     80 | |     ($($T:ident)*) => {
     81 | |         $(
     82 | |             #[stable(feature = "rust1", since = "1.0.0")]
    ...   |
     85 | |                 fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
        | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    ...   |
     96 | |     };
     97 | | }
        | |_- in this expansion of `impl_Debug!`
    ...
    595 | / impl_Debug! {
    596 | |     i8 i16 i32 i64 i128 isize
    597 | |     u8 u16 u32 u64 u128 usize
    598 | | }
        | |_- in this macro invocation

Presumably this comes from the call to `panicking::assert_failed!` that
needs to be monomorphized. Avoid any formatting by using a plain
`debug_assert!` if we are building the crate as compiler-builtins.
LLVM doesn't currently emit this but probably should, and this is
valuable as a fallback in any case.
…ertdev,tgross35

`core::num::f16b` Rust's 16bit Brain Float

Implements the [RFC: f16b type](rust-lang/rfcs#3983). Best reviewed commit by commit, happy to split into separate PRs if that is deemed easier to review. However the line count and surface area is, in my opinion, reasonably small.

Adds;
- ABI plumbing for the `f16b` along with `bfloat` lang item to work with LLVM, GCC is explicitly `unimplemented!(...)`
- `f16b` feature gate, page for `f16b` on libruscdoc and a `struct bf16` in `core::num`
- Tests
- Treat `f16b` as a scalar primitive for scalable vectors

Issues;
- [Tracking Issue](rust-lang#160630)
- [RFC](rust-lang/rfcs#3983)
@rust-bors rust-bors Bot added the rollup A PR which is a rollup label Sep 17, 2026
@rustbot rustbot added A-attributes Area: Attributes (`#[…]`, `#![…]`) A-compiler-builtins Area: compiler-builtins (https://github.com/rust-lang/compiler-builtins) A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-test-infra-minicore Area: `minicore` test auxiliary and `//@ add-core-stubs` A-tidy Area: The tidy tool PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rust-analyzer Relevant to the rust-analyzer team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. T-rustdoc-frontend Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output. labels Sep 17, 2026
@JonathanBrouwer

Copy link
Copy Markdown
Member Author

@bors r+ p=1

Trying commonly failed jobs
@bors try jobs=dist-various-1,test-various,test-x86_64-gnu-aux,test-x86_64-gnu-llvm-21-3,test-x86_64-msvc-1,test-aarch64-apple-1,test-aarch64-apple-2,test-x86_64-mingw-1,test-i686-msvc,test-armhf-gnu

@rust-bors

rust-bors Bot commented Sep 17, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 9edabb4 has been approved by JonathanBrouwer

It is now in the queue for this repository.

@rust-bors rust-bors Bot 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 Sep 17, 2026
@rust-bors

This comment has been minimized.

rust-bors Bot pushed a commit that referenced this pull request Sep 17, 2026
Rollup of 10 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
@rust-log-analyzer

Copy link
Copy Markdown
Collaborator

The job test-pr-check-2 failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
[RUSTC-TIMING] rustc_hir_analysis test:false 8.214
    Checking rustc_hir_typeck v0.0.0 (/checkout/compiler/rustc_hir_typeck)
[RUSTC-TIMING] rustc_mir_build test:false 3.784
    Checking rustc_traits v0.0.0 (/checkout/compiler/rustc_traits)
error[E0004]: non-exhaustive patterns: `rustc_abi::Primitive::Float(rustc_abi::Float::F16B)` not covered
    --> compiler/rustc_codegen_llvm/src/va_arg.rs:480:50
     |
 480 |             BackendRepr::Scalar(scalar) => match scalar.primitive() {
     |                                                  ^^^^^^^^^^^^^^^^^^ pattern `rustc_abi::Primitive::Float(rustc_abi::Float::F16B)` not covered
     |
note: `rustc_abi::Primitive` defined here
    --> compiler/rustc_abi/src/lib.rs:1498:1
     |
1498 | pub enum Primitive {
     | ^^^^^^^^^^^^^^^^^^
...
1507 |     Float(Float),
     |     ----- not covered
     = note: the matched value is of type `rustc_abi::Primitive`
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
     |
 483 ~                 Primitive::Int(_, _) | Primitive::Pointer(_) => false,
 484 ~                 rustc_abi::Primitive::Float(rustc_abi::Float::F16B) => todo!(),
     |

For more information about this error, try `rustc --explain E0004`.
[RUSTC-TIMING] rustc_codegen_llvm test:false 3.712
error: could not compile `rustc_codegen_llvm` (lib) due to 1 previous error

@rust-bors rust-bors Bot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Sep 17, 2026
@rust-log-analyzer

Copy link
Copy Markdown
Collaborator

The job test-x86_64-gnu-aux failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
[RUSTC-TIMING] rustc_lint test:false 59.165
   Compiling rustc_ty_utils v0.0.0 (/checkout/compiler/rustc_ty_utils)
[RUSTC-TIMING] rustc_const_eval test:false 54.444
   Compiling rustc_mir_transform v0.0.0 (/checkout/compiler/rustc_mir_transform)
error[E0004]: non-exhaustive patterns: `rustc_abi::Primitive::Float(rustc_abi::Float::F16B)` not covered
    --> compiler/rustc_codegen_llvm/src/va_arg.rs:480:50
     |
 480 |             BackendRepr::Scalar(scalar) => match scalar.primitive() {
     |                                                  ^^^^^^^^^^^^^^^^^^ pattern `rustc_abi::Primitive::Float(rustc_abi::Float::F16B)` not covered
     |
note: `rustc_abi::Primitive` defined here
    --> compiler/rustc_abi/src/lib.rs:1498:1
     |
1498 | pub enum Primitive {
     | ^^^^^^^^^^^^^^^^^^
...
1507 |     Float(Float),
     |     ----- not covered
     = note: the matched value is of type `rustc_abi::Primitive`
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
     |
 483 ~                 Primitive::Int(_, _) | Primitive::Pointer(_) => false,
 484 ~                 rustc_abi::Primitive::Float(rustc_abi::Float::F16B) => todo!(),
     |

For more information about this error, try `rustc --explain E0004`.
[RUSTC-TIMING] rustc_codegen_llvm test:false 3.550
error: could not compile `rustc_codegen_llvm` (lib) due to 1 previous error
---
Currently active steps:
compile::Assemble { target_compiler: Compiler { stage: 1, host: x86_64-unknown-linux-gnu, forced_compiler: false } } at src/bootstrap/src/core/build_steps/tool.rs:375
compile::Rustc { target: x86_64-unknown-linux-gnu, build_compiler: Compiler { stage: 0, host: x86_64-unknown-linux-gnu, forced_compiler: false }, crates: [] } at src/bootstrap/src/core/build_steps/compile.rs:2328
Build completed unsuccessfully in 0:05:56
make: *** [Makefile:51: check-aux] Error 1
  local time: Thu Sep 17 18:28:58 UTC 2026
  network time: Thu, 17 Sep 2026 18:28:58 GMT
##[error]Process completed with exit code 2.
##[group]Run echo "disk usage:"
echo "disk usage:"

@rust-bors

rust-bors Bot commented Sep 17, 2026

Copy link
Copy Markdown
Contributor

PR #160859, which is a member of this rollup, was unapproved.

This rollup was thus unapproved.

@rustbot rustbot removed the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Sep 17, 2026
@rust-bors rust-bors Bot added the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Sep 17, 2026
@rust-bors

rust-bors Bot commented Sep 17, 2026

Copy link
Copy Markdown
Contributor

💔 Test for a5598e9 failed: CI. Failed jobs:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-attributes Area: Attributes (`#[…]`, `#![…]`) A-compiler-builtins Area: compiler-builtins (https://github.com/rust-lang/compiler-builtins) A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-test-infra-minicore Area: `minicore` test auxiliary and `//@ add-core-stubs` A-tidy Area: The tidy tool PG-exploit-mitigations Project group: Exploit mitigations rollup A PR which is a rollup S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rust-analyzer Relevant to the rust-analyzer team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. T-rustdoc-frontend Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.

Projects

None yet

Development

Successfully merging this pull request may close these issues.