Skip to content

redesign stage 0 std follow-ups #141914

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

Merged
merged 5 commits into from
Jun 3, 2025
Merged

redesign stage 0 std follow-ups #141914

merged 5 commits into from
Jun 3, 2025

Conversation

onur-ozkan
Copy link
Member

@onur-ozkan onur-ozkan commented Jun 2, 2025

Various follow-ups pointed out on Zulip during post-merge discussions of redesign stage 0 std #119899.

r? @jieyouxu

Fixes #141902.
Fixes #141905.

cc @jyn514

@rustbot rustbot added A-testsuite Area: The testsuite used to check the correctness of rustc T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. labels Jun 2, 2025
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.

Looks good to me modulo changelog entry and a nit.

Consistent with what we discussed in #t-infra/bootstrap > Stage 0 std redesign support thread @ 💬.

@rust-log-analyzer

This comment has been minimized.

@onur-ozkan onur-ozkan force-pushed the follow-ups branch 2 times, most recently from 6692543 to 118eb4c Compare June 2, 2025 14:03
@onur-ozkan onur-ozkan marked this pull request as ready for review June 2, 2025 14:03
@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jun 2, 2025
@rustbot
Copy link
Collaborator

rustbot commented Jun 2, 2025

This PR modifies src/bootstrap/defaults.

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

@onur-ozkan
Copy link
Member Author

Currently blocked by #141904

@rustbot blocked.

@rustbot rustbot added S-blocked Status: Blocked on something else such as an RFC or other implementation work. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 2, 2025
@@ -27,6 +27,7 @@ COPY scripts/sccache.sh /scripts/
RUN sh /scripts/sccache.sh

ENV SCRIPT \
python3 ../x.py check --stage 0 && \
Copy link
Member Author

Choose a reason for hiding this comment

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

I am not entirely sure about this yet. If it makes the pipeline too long, we can consider moving it to some other PR pipeline.

Copy link
Member Author

@onur-ozkan onur-ozkan Jun 3, 2025

Choose a reason for hiding this comment

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

It still seems to be roughly the same duration as mingw-check-1 (only about 3.5 minutes longer).

Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah this seems fine.

Copy link
Member Author

@onur-ozkan onur-ozkan Jun 3, 2025

Choose a reason for hiding this comment

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

Not needed anymore. It's still needed actually. I will keep it.

@rust-log-analyzer

This comment has been minimized.

@jieyouxu
Copy link
Member

jieyouxu commented Jun 2, 2025

For a second opinion of hard-error on check library at explicit stage 0.
r? bootstrap

@rustbot rustbot assigned Mark-Simulacrum and unassigned jieyouxu Jun 2, 2025
@bjorn3
Copy link
Member

bjorn3 commented Jun 2, 2025

If I want to check the standard library, how would I do so with this PR?

@onur-ozkan
Copy link
Member Author

If I want to check the standard library, how would I do so with this PR?

x check library on non-compiler profile and x check --stage 1 library on compiler profile.

@onur-ozkan
Copy link
Member Author

@rustbot ready

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-blocked Status: Blocked on something else such as an RFC or other implementation work. labels Jun 3, 2025
@onur-ozkan
Copy link
Member Author

We probably want some quicker action on this.

r? Kobzol

@rustbot rustbot assigned Kobzol and unassigned Mark-Simulacrum Jun 3, 2025
Copy link
Contributor

@Kobzol Kobzol left a comment

Choose a reason for hiding this comment

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

Left some comments, but if we switch the default stage of check back to 0, it won't be relevant anymore, I guess :)

@@ -27,6 +27,7 @@ COPY scripts/sccache.sh /scripts/
RUN sh /scripts/sccache.sh

ENV SCRIPT \
python3 ../x.py check --stage 0 && \
Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah this seems fine.

@rustbot
Copy link
Collaborator

rustbot commented Jun 3, 2025

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

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

Signed-off-by: onur-ozkan <work@onurozkan.dev>
Signed-off-by: onur-ozkan <work@onurozkan.dev>
@onur-ozkan
Copy link
Member Author

Left some comments, but if we switch the default stage of check back to 0, it won't be relevant anymore, I guess :)

I thought the same, but then I realized that we run check --stage 1 on PR CI. So it still makes sense to run the default x check on mingw-check-2. It's also nice that we cover both stage 0 and stage 1 in PR CI and they are not increasing the pipeline unexpectedly.

Comment on lines +82 to +95
if is_explicitly_called {
eprintln!("WARNING: stage 0 std is precompiled and does nothing during `x check`.");
}
Copy link
Member Author

Choose a reason for hiding this comment

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

Should we give this warning unconditionally, or keep it as it is?

Copy link
Contributor

Choose a reason for hiding this comment

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

I would only keep it when the library was explicitly requested, so this seems fine.

@onur-ozkan
Copy link
Member Author

If I want to check the standard library, how would I do so with this PR?

x check library on non-compiler profile and x check --stage 1 library on compiler profile.

This is changed. To check library, you should either do x check library --stage 1 on non-library profile, or x check library on the library profile.

cc @bjorn3

@Kobzol
Copy link
Contributor

Kobzol commented Jun 3, 2025

Looks good. You can r=me once CI is green.

Signed-off-by: onur-ozkan <work@onurozkan.dev>
Signed-off-by: onur-ozkan <work@onurozkan.dev>
@onur-ozkan
Copy link
Member Author

onur-ozkan commented Jun 3, 2025

If I want to check the standard library, how would I do so with this PR?

x check library on non-compiler profile and x check --stage 1 library on compiler profile.

This is changed. To check library, you should either do x check library --stage 1 on non-library profile, or x check library on the library profile.

cc @bjorn3

Updated again (sorry). Now you just need to run x check library regardless of the profile. check::Std is now smart enough to pick the best default even when the stage isn't explicitly set.

@onur-ozkan
Copy link
Member Author

onur-ozkan commented Jun 3, 2025

Looks good. You can r=me once CI is green.

This was pushed after you approved the PR. Are you okay with that commit as well?

Signed-off-by: onur-ozkan <work@onurozkan.dev>
@Kobzol
Copy link
Contributor

Kobzol commented Jun 3, 2025

Yeah, I'm fine with that.

@onur-ozkan
Copy link
Member Author

@bors r+ r=Kobzol

@bors
Copy link
Collaborator

bors commented Jun 3, 2025

📌 Commit 59d993b has been approved by onur-ozkan

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 Jun 3, 2025
@bors
Copy link
Collaborator

bors commented Jun 3, 2025

📌 Commit 59d993b has been approved by Kobzol

It is now in the queue for this repository.

@onur-ozkan
Copy link
Member Author

I think I have never seen bors duplicating the merge message before. 🤔

@jieyouxu
Copy link
Member

jieyouxu commented Jun 3, 2025

I think I have never seen bors duplicating the merge message before. 🤔

You wrote r+ and r= :D

@onur-ozkan
Copy link
Member Author

lol, seems like I didn't sleep enough

bors added a commit that referenced this pull request Jun 3, 2025
Rollup of 8 pull requests

Successful merges:

 - #141724 (fix(#141141): When expanding `PartialEq`, check equality of scalar types first.)
 - #141833 (`tests/ui`: A New Order [2/N])
 - #141861 (Switch `x86_64-msvc-{1,2}` back to Windows Server 2025 images)
 - #141914 (redesign stage 0 std follow-ups)
 - #141918 (Deconstruct values in the THIR visitor)
 - #141923 (Update books)
 - #141931 (Deconstruct values in the THIR visitor)
 - #141956 (Remove two trait methods from cg_ssa)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 72f60fb into rust-lang:master Jun 3, 2025
10 checks passed
@rustbot rustbot added this to the 1.89.0 milestone Jun 3, 2025
rust-timer added a commit that referenced this pull request Jun 3, 2025
Rollup merge of #141914 - onur-ozkan:follow-ups, r=Kobzol

redesign stage 0 std follow-ups

Various follow-ups pointed out on Zulip during post-merge discussions of [redesign stage 0 std #119899](#119899).

r? `@jieyouxu`

Fixes #141902.
Fixes #141905.

cc `@jyn514`
@onur-ozkan onur-ozkan deleted the follow-ups branch June 4, 2025 02:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-testsuite Area: The testsuite used to check the correctness of rustc 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-infra Relevant to the infrastructure team, which will review and decide on the PR/issue.
Projects
None yet
8 participants