Skip to content

Fix x bench library/std - #165762

Merged
rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
adamgemmell:dev/adagem01/bench-library
Nov 10, 2026
Merged

rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
adamgemmell:dev/adagem01/bench-library

Conversation

@adamgemmell

Copy link
Copy Markdown
Contributor

Since #149514, bootstrap was building std with the dist profile, but still using the default profile for cargo bench. This PR fixes that by ensuring that operations on std always use the dist profile.

@rustbot

rustbot commented Nov 10, 2026

Copy link
Copy Markdown
Collaborator

Some changes occurred in src/tools/enzyme

cc @ZuseZ4

Some changes occurred in src/tools/cargo

cc @weihanglo

@rustbot rustbot added F-autodiff `#![feature(autodiff)]` 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) labels Nov 10, 2026
@rustbot

rustbot commented Nov 10, 2026

Copy link
Copy Markdown
Collaborator

r? @jieyouxu

rustbot has assigned @jieyouxu.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: bootstrap
  • bootstrap expanded to 6 candidates
  • Random selection from Mark-Simulacrum, clubby789, jieyouxu

@rustbot

This comment has been minimized.

@adamgemmell
adamgemmell force-pushed the dev/adagem01/bench-library branch from d9e61f5 to dcaa2aa Compare November 10, 2026 15:01
@adamgemmell adamgemmell removed the F-autodiff `#![feature(autodiff)]` label Nov 10, 2026
@adamgemmell

Copy link
Copy Markdown
Contributor Author

Sorry for the pings, I committed my out of date submodules again

r? reroll

@rustbot

rustbot commented Nov 10, 2026

Copy link
Copy Markdown
Collaborator

Error: Failed to set assignee to reroll: invalid assignee

Note: Only org members with at least the repository "read" role, users with write permissions, or people who have commented on the PR may be assigned.

Please file an issue on GitHub at triagebot if there's a problem with this bot, or reach out on #triagebot on Zulip.

@adamgemmell

Copy link
Copy Markdown
Contributor Author

r? bootstrap

@rustbot rustbot assigned Mark-Simulacrum and unassigned jieyouxu Nov 10, 2026
Comment thread src/bootstrap/src/core/builder/cargo.rs Outdated
// Some std configuration exists in its own profile
(_, Mode::Std) => Some("dist"),
// Otherwise, bench with the default profile, never dev
(Kind::Bench, _) => None,

@bjorn3 bjorn3 Nov 10, 2026 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Testing and benchmarking shouldn't use the default profile. They should use the exact same profile (and all other cargo configs) as the standard library contained in the sysroot was compiled with.

View changes since the review

@adamgemmell adamgemmell Nov 10, 2026 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True, that behaviour was a relic from when bootstrap used to pass --release which cargo bench doesn't accept. I've removed that line so the profile should always match now

@adamgemmell
adamgemmell force-pushed the dev/adagem01/bench-library branch from dcaa2aa to 3e405fc Compare November 10, 2026 15:48
@Kobzol

Kobzol commented Nov 10, 2026

Copy link
Copy Markdown
Member

r? kobzol

Thanks!

@bors r+

@rust-bors

rust-bors Bot commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 3e405fc has been approved by Kobzol

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 Nov 10, 2026
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Nov 10, 2026
…rary, r=Kobzol

Fix `x bench library/std`

Since rust-lang#149514, bootstrap was building std with the dist profile, but still using the default profile for `cargo bench`. This PR fixes that by ensuring that operations on std always use the dist profile.
rust-bors Bot pushed a commit that referenced this pull request Nov 10, 2026
…uwer

Rollup of 8 pull requests

Successful merges:

 - #158970 (Support underscore as associated const name in inherent impls)
 - #165192 (BPF: Define max/min atomic width per CPU version)
 - #165611 (Avoid terminator: None in MIR building)
 - #165749 (Improve duplicate attribute diagnostics for active built-in attributes)
 - #165762 (Fix `x bench library/std`)
 - #165726 ([rustdoc-frontend] Properly clear search state when sidebar link is clicked)
 - #165728 (Disable no_threads compiler errors for Trusty targets)
 - #165754 (rustdoc: Rename `--show-coverage` CLI flag into `--coverage`)
rust-bors Bot pushed a commit that referenced this pull request Nov 10, 2026
…uwer

Rollup of 7 pull requests

Successful merges:

 - #165192 (BPF: Define max/min atomic width per CPU version)
 - #165611 (Avoid terminator: None in MIR building)
 - #165749 (Improve duplicate attribute diagnostics for active built-in attributes)
 - #165762 (Fix `x bench library/std`)
 - #165726 ([rustdoc-frontend] Properly clear search state when sidebar link is clicked)
 - #165728 (Disable no_threads compiler errors for Trusty targets)
 - #165754 (rustdoc: Rename `--show-coverage` CLI flag into `--coverage`)
@rust-bors
rust-bors Bot merged commit c592272 into rust-lang:main Nov 10, 2026
14 checks passed
@rustbot rustbot added this to the 1.102.0 milestone Nov 10, 2026
rust-bors Bot pushed a commit that referenced this pull request Nov 10, 2026
Rollup merge of #165762 - adamgemmell:dev/adagem01/bench-library, r=Kobzol

Fix `x bench library/std`

Since #149514, bootstrap was building std with the dist profile, but still using the default profile for `cargo bench`. This PR fixes that by ensuring that operations on std always use the dist profile.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants