Skip to content
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

Bump boostrap compiler to new beta #133533

Merged
merged 5 commits into from
Nov 30, 2024
Merged

Conversation

BoxyUwU
Copy link
Member

@BoxyUwU BoxyUwU commented Nov 27, 2024

Currently failing due to something about the const stability checks and panic!. I'm not sure why though since I wasn't able to see any PRs merged in the past few days that would result in a cfg(bootstrap) that shouldn't be removed. cc @RalfJung #131349

@rustbot
Copy link
Collaborator

rustbot commented Nov 27, 2024

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

@rustbot rustbot added O-apple Operating system: Apple (macOS, iOS, tvOS, visionOS, watchOS) 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-release Relevant to the release subteam, which will review and decide on the PR/issue. labels Nov 27, 2024
@rustbot
Copy link
Collaborator

rustbot commented Nov 27, 2024

library/core/src/unicode/unicode_data.rs is generated by
src/tools/unicode-table-generator via ./x run src/tools/unicode-table-generator. If you want to modify unicode_data.rs,
please modify the tool then regenerate the library source file with the tool
instead of editing the library source file manually.

Some changes occurred to the intrinsics. Make sure the CTFE / Miri interpreter
gets adapted for the changes, if necessary.

cc @rust-lang/miri, @rust-lang/wg-const-eval

@rust-log-analyzer

This comment has been minimized.

@RalfJung
Copy link
Member

RalfJung commented Nov 27, 2024

There are some cfg_attr(bootstrap, ...) that you did not remove, like here:

bootstrap,

Probably it's related to them being broken across multiple lines. rustfmt enforces that... but it might be tricky yo update your scripts to support that.

@BoxyUwU
Copy link
Member Author

BoxyUwU commented Nov 27, 2024

Ah.... yep that would do it. There was some cfg(not(bootstrap), split across multiple lines that i did notice but didn't see those. Thanks

@rustbot
Copy link
Collaborator

rustbot commented Nov 27, 2024

Some changes occurred to the intrinsics. Make sure the CTFE / Miri interpreter
gets adapted for the changes, if necessary.

cc @rust-lang/miri, @rust-lang/wg-const-eval

library/core/src/unicode/unicode_data.rs is generated by
src/tools/unicode-table-generator via ./x run src/tools/unicode-table-generator. If you want to modify unicode_data.rs,
please modify the tool then regenerate the library source file with the tool
instead of editing the library source file manually.

This PR modifies src/bootstrap/src/core/config.

If appropriate, please update CONFIG_CHANGE_HISTORY in src/bootstrap/src/utils/change_tracker.rs.

Copy link
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

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

Thanks

@jieyouxu
Copy link
Member

AFAICT this looks good.
@bors r+ rollup=never p=1 (bootstrap compiler bump)

@bors
Copy link
Contributor

bors commented Nov 27, 2024

📌 Commit 583e26c has been approved by jieyouxu

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 Nov 27, 2024
@jieyouxu
Copy link
Member

@bors p=10 (potentially conflict-prone)

@bors
Copy link
Contributor

bors commented Nov 27, 2024

⌛ Testing commit 583e26c with merge 64ab128...

bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 27, 2024
Bump boostrap compiler to new beta

Currently failing due to something about the const stability checks and `panic!`. I'm not sure why though since I wasn't able to see any PRs merged in the past few days that would result in a `cfg(bootstrap)` that shouldn't be removed. cc `@RalfJung` rust-lang#131349
@rust-log-analyzer

This comment has been minimized.

@bors
Copy link
Contributor

bors commented Nov 27, 2024

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Nov 27, 2024
@bors bors added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 28, 2024
@BoxyUwU
Copy link
Member Author

BoxyUwU commented Nov 28, 2024

not spurious :^)

@RalfJung
Copy link
Member

Seems like it's a cargo test that failed?
Cc @rust-lang/cargo

@weihanglo
Copy link
Member

The nightly CARGO_RUSTC_CURRENT_DIR environment variable has been removed. Cargo needs to adjust this hack maybe. Let me check.

weihanglo added a commit to weihanglo/cargo that referenced this pull request Nov 29, 2024
The environment variable has been removed in rust-lang#14799
Switch to plain old `CARGO_MANIFEST_DIR` instead.

See also build failures in rust-lang/rust#133533
weihanglo added a commit to weihanglo/cargo that referenced this pull request Nov 29, 2024
The environment variable has been removed in rust-lang#14799.
Switch to plain old `CARGO_MANIFEST_DIR`
because snapbox's `current_rs` favors furthest Cargo.toml,
blocking tests running in rust-lang/rust as a submodule.

See also build failures in rust-lang/rust#133533
@epage
Copy link
Contributor

epage commented Nov 29, 2024

We removed that 3 weeks ago (rust-lang/cargo#14799), why is it just now causing problems?

@RalfJung
Copy link
Member

RalfJung commented Nov 29, 2024

Because this PR updates the cargo used for Rust bootstraping to the just-released beta.

weihanglo added a commit to weihanglo/cargo that referenced this pull request Nov 29, 2024
The environment variable has been removed in rust-lang#14799.
Switch to plain old `CARGO_MANIFEST_DIR`
because snapbox's `current_rs` favors furthest Cargo.toml,
blocking tests running in rust-lang/rust as a submodule.

See also build failures in rust-lang/rust#133533
weihanglo added a commit to weihanglo/cargo that referenced this pull request Nov 29, 2024
The environment variable has been removed in rust-lang#14799.
Switch to plain old `CARGO_MANIFEST_DIR`
because snapbox's `current_rs` favors furthest Cargo.toml,
blocking tests running in rust-lang/rust as a submodule.

See also build failures in rust-lang/rust#133533
weihanglo added a commit to weihanglo/cargo that referenced this pull request Nov 29, 2024
The environment variable has been removed in rust-lang#14799.
Switch to plain old `CARGO_MANIFEST_DIR`
because snapbox's `current_rs` favors furthest Cargo.toml,
blocking tests running in rust-lang/rust as a submodule.

See also build failures in rust-lang/rust#133533
@weihanglo
Copy link
Member

weihanglo commented Nov 29, 2024

@BoxyUwU this patch should fix the test failures.

However since it changes bootstrap, I would recommend looping some bootstrap team folks to have a look.

diff --git a/src/bootstrap/src/core/build_steps/test.rs b/src/bootstrap/src/core/build_steps/test.rs
index dd967bca867..1c24ccc3216 100644
--- a/src/bootstrap/src/core/build_steps/test.rs
+++ b/src/bootstrap/src/core/build_steps/test.rs
@@ -263,12 +263,16 @@ pub struct Cargo {
     host: TargetSelection,
 }
 
+impl Cargo {
+    const CRATE_PATH: &str = "src/tools/cargo";
+}
+
 impl Step for Cargo {
     type Output = ();
     const ONLY_HOSTS: bool = true;
 
     fn should_run(run: ShouldRun<'_>) -> ShouldRun<'_> {
-        run.path("src/tools/cargo")
+        run.path(Self::CRATE_PATH)
     }
 
     fn make_run(run: RunConfig<'_>) {
@@ -286,7 +290,7 @@ fn run(self, builder: &Builder<'_>) {
             Mode::ToolRustc,
             self.host,
             Kind::Test,
-            "src/tools/cargo",
+            Self::CRATE_PATH,
             SourceType::Submodule,
             &[],
         );
@@ -301,6 +305,9 @@ fn run(self, builder: &Builder<'_>) {
         // those features won't be able to land.
         cargo.env("CARGO_TEST_DISABLE_NIGHTLY", "1");
         cargo.env("PATH", path_for_cargo(builder, compiler));
+        // Cargo's test suite requires configurations from its own `.cargo/config.toml`.
+        // Change to the directory so Cargo can read from it.
+        cargo.current_dir(builder.src.join(Self::CRATE_PATH));
 
         #[cfg(feature = "build-metrics")]
         builder.metrics.begin_test_suite(

@Mark-Simulacrum
Copy link
Member

Cargo patch looks fine to me.

@BoxyUwU
Copy link
Member Author

BoxyUwU commented Nov 29, 2024

@bors r=jieyouxu,Mark-Simulacrum

@bors
Copy link
Contributor

bors commented Nov 29, 2024

📌 Commit 5fa483c has been approved by jieyouxu,Mark-Simulacrum

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 Nov 29, 2024
@bors
Copy link
Contributor

bors commented Nov 29, 2024

⌛ Testing commit 5fa483c with merge 1fc691e...

@bors
Copy link
Contributor

bors commented Nov 30, 2024

☀️ Test successful - checks-actions
Approved by: jieyouxu,Mark-Simulacrum
Pushing 1fc691e to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Nov 30, 2024
@bors bors merged commit 1fc691e into rust-lang:master Nov 30, 2024
7 checks passed
@rustbot rustbot added this to the 1.85.0 milestone Nov 30, 2024
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (1fc691e): comparison URL.

Overall result: ✅ improvements - no action needed

@rustbot label: -perf-regression

Instruction count

This is the most reliable metric that we have; it was used to determine the overall result at the top of this comment. However, even this metric can sometimes exhibit noise.

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

Max RSS (memory usage)

Results (secondary 2.3%)

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

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

Cycles

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

Binary size

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

Bootstrap: 773.513s -> 773.861s (0.04%)
Artifact size: 332.31 MiB -> 332.29 MiB (-0.01%)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. O-apple Operating system: Apple (macOS, iOS, tvOS, visionOS, watchOS) 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) 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-release Relevant to the release subteam, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants