Skip to content

Rollup of 10 pull requests - #161704

Closed
GuillaumeGomez wants to merge 33 commits into
rust-lang:mainfrom
GuillaumeGomez:rollup-t5EHhDi
Closed

Rollup of 10 pull requests#161704
GuillaumeGomez wants to merge 33 commits into
rust-lang:mainfrom
GuillaumeGomez:rollup-t5EHhDi

Conversation

@GuillaumeGomez

Copy link
Copy Markdown
Member

Successful merges:

r? @ghost

Create a similar rollup

durin42 and others added 30 commits August 14, 2026 10:53
LLVM 24 stopped using llvm::Any here to avoid heap allocations in
PassInstrumentation.
Before, LargeDataThreshold was only set via `LLVMRustCreateTargetMachine`.
When LTO is enabled, this information is required to be passed into the
generated LLVM module IR files since the LTO linker spins up its own
TargetMachine and otherwise has no knowledge of the LargeDataThreshold.

Currently, `-Z large-data-threshold` has no affect at all when compiling
with LTO.
This commit makes sure that if `-Z large-data-threshold` is passed and
not 0, it is preserved and stored into the generated LLVM IR.
The essential problem is that, with this table:

```text
one |
----|
  a | b | c
  a | b |
  a | b
  a |
```

And this logic:

```rust
let too_many_pipes = divider_count > expected_cells + 1;
```

`expected_cells + 1` winds up as 2, so you get this warning:

```text
error: unused content after last table cell
  --> $DIR/invalid_markdown_table.rs:81:14
   |
LL |     //!   a | b | c
   |              ^^^^^^ this content is discarded

error: unused content after last table cell
  --> $DIR/invalid_markdown_table.rs:83:14
   |
LL |     //!   a | b |
   |              ^^^^ this content is discarded

error: unused content after last table cell
  --> $DIR/invalid_markdown_table.rs:85:14
   |
LL |     //!   a | b
   |              ^^ this content is discarded
```

We really want our warning to give the suggest-escaping flow, like this:

```text
error: table row has too many columns
  --> $DIR/invalid_markdown_table.rs:81:13
   |
LL |     //!   a | b | c
   |             ^ any content after this column divider is discarded
   |
   = help: to escape `|` characters in tables, add a `\` before them like `\|`

error: table row has too many columns
  --> $DIR/invalid_markdown_table.rs:83:13
   |
LL |     //!   a | b |
   |             ^ any content after this column divider is discarded
   |
   = help: to escape `|` characters in tables, add a `\` before them like `\|`

error: unused content after last table cell
  --> $DIR/invalid_markdown_table.rs:85:14
   |
LL |     //!   a | b
   |              ^^ this content is discarded
```

By only scanning the text between the end of the last cell and the row,
instead of doing the entire row, we don't have to re-implement as much
of pulldown-cmark's logic.
Previously, the code unwrapped large_data_threshold with a default of
0 and sets it in the LLVM module if it is != 0.
Instead, we should simply check if large_data_threshold has a value.
bootstrap: don't LTO C dependencies on aarch64

Since rust-lang#161535 apparently may take a while, let's land something to un-break Miri: we know that on aarch64-linux, shipping pure-LTO object files is a bad idea as we can't assume the user has an LTO-capable linker.

r? @Kobzol
Cc @weihanglo
…, r=GuillaumeGomez

rustdoc: fix issue preventing "read more" links from generating.

fixes rust-lang#161300
…nagisa

Pass LargeDataThreshold to LLVM module IR

Before, LargeDataThreshold was only set via `LLVMRustCreateTargetMachine`. When LTO is enabled, this information is required to be passed into the generated LLVM module IR files since the LTO linker spins up its own TargetMachine and otherwise has no knowledge of the LargeDataThreshold.

Currently, `-Z large-data-threshold` has no affect at all when compiling with LTO.
This commit makes sure that if `-Z large-data-threshold` is passed and not 0, it is preserved and stored into the generated LLVM IR.
…=GuillaumeGomez

rustdoc: Nuke `--passes=list` and defossilize the passes infrastructure

`--passes` and `--no-defaults` were deprecated and made noops years ago except that `--passes list` still prints all passes in a human-readable format as if users could still somehow make use of that information. Removing this useless functionality allows for some small simplifications (and longer term, it would enable us to further rewrite the way we represent internal passes w/o having to worry about it possibly affecting the CLI).

Given that the output of `--passes list` is *clearly* meant for human consumption only (I mean, just look at it), I hold the opinion that this removal doesn't need an FCP. And even if there were scripts somewhere out there that try to parse this output I think it would be okay to break them.
…t-links-url, r=GuillaumeGomez

Check `redundant_explicit_links` against generated URLs

Fixes rust-lang#155458.

`rustdoc::redundant_explicit_links` checked explicit link destinations by resolving both the label and the destination as intra-doc paths. That misses links written as local rustdoc page URLs, such as `struct.B.html`, because those URLs do not appear in `doc_link_resolutions`.

This PR keeps the existing path-resolution check and falls back to comparing the explicit destination with the local href that rustdoc would generate for the resolved label.
remove `box_patterns`

This PR removes the old feature `box_patterns`, tracked in rust-lang#29641. As explained in rust-lang#29641 (comment), this feature will not be stabilized since `deref_patterns` (rust-lang#87121) is a better and more general version of this feature.

It was not possible to remove this feature until recently since the compiler itself still depended on this feature. This was changed with rust-lang/compiler-team#984.

This PR currently breaks crates that rely on box patterns using the incorrect pre-expansion feature gating (see rust-lang#154045 for more details). Therefore, this needs a crater run.

Closes rust-lang#29641.
Closes rust-lang#105099.
Closes rust-lang#156110.
…able_cell, r=Urgau,notriddle,camelid

Add new `invalid_markdown_table` rustdoc lint

Fixes rust-lang#159186.

r? @Urgau
…=cuviper

PassWrapper: handle LLVM 24 change in function types

LLVM 24 stopped using llvm::Any here [to avoid heap allocations](llvm/llvm-project@fa23198) in PassInstrumentation.

@rustbot label: +llvm-main
…k-fix, r=cuviper

Check for missing rustfmt in the stdarch intrinsic test step sooner

Found [here](rust-lang#161422 (comment)).

r? cuviper
…re, r=ChrisDenton

Don't treat slashes as path seps after drive letters in verbatim paths

Treat slashes as just a regular character in `\\?\C:/path\somewhere`. This mirrors how slashes are treated afterwards, e.g. in `\\?\C:\path/somewhere`, which has a component `path/somewhere`, rather than `path`, `somewhere`.

Likewise, drive letters followed by `/` do not denote a `VerbatimDisk`, but an arbitrary `Verbatim` path: The prefix of `\\?\C:/path\somewhere` is `\\?\C:/path`.

Fixes rust-lang#161651
@rust-bors rust-bors Bot added the rollup A PR which is a rollup label Aug 24, 2026
@rustbot rustbot added A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-testsuite Area: The testsuite used to check the correctness of rustc 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-clippy Relevant to the Clippy team. 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-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. T-rustfmt Relevant to the rustfmt team, which will review and decide on the PR/issue. labels Aug 24, 2026
@GuillaumeGomez

Copy link
Copy Markdown
Member Author

@bors r+ p=5

@rust-bors

rust-bors Bot commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

📌 Commit ff895cf has been approved by GuillaumeGomez

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 Aug 24, 2026
@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 Aug 24, 2026
@rust-bors

rust-bors Bot commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

☔ The latest upstream changes made this pull request unmergeable. Please resolve the merge conflicts by rebasing.

This pull request was 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 Aug 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-testsuite Area: The testsuite used to check the correctness of rustc rollup A PR which is a rollup T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-clippy Relevant to the Clippy team. 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-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. T-rustfmt Relevant to the rustfmt team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.