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

change config.toml to bootstrap.toml #137081

Conversation

Shourya742
Copy link
Contributor

@Shourya742 Shourya742 commented Feb 15, 2025

Currently, both Bootstrap and Cargo uses same name as their configuration file, which can be confusing. This PR is based on a discussion to rename config.toml to bootstrap.toml for Bootstrap. Closes: #126875.

I have split the PR into atomic commits to make it easier to review. Once the changes are finalized, I will squash them. I am particularly concerned about the changes made to modules that are not part of Bootstrap. How should we handle those changes? Should we ping the respective maintainers?

@rustbot
Copy link
Collaborator

rustbot commented Feb 15, 2025

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
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
Copy link
Collaborator

rustbot commented Feb 15, 2025

Failed to set assignee to onur: 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.

@Shourya742
Copy link
Contributor Author

r? @onur-ozkan

@rust-log-analyzer

This comment has been minimized.

@Shourya742 Shourya742 force-pushed the 2025-02-15-change-config.toml-to-bootstrap.toml branch from 044bdca to 58f42a6 Compare February 15, 2025 15:49
@rustbot rustbot added A-compiletest Area: The compiletest test runner A-meta Area: Issues & PRs about the rust-lang/rust repository itself A-run-make Area: port run-make Makefiles to rmake.rs A-rustc-dev-guide Area: rustc-dev-guide A-testsuite Area: The testsuite used to check the correctness of rustc O-solid Operating System: SOLID O-windows Operating system: Windows PG-exploit-mitigations Project group: Exploit mitigations 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-infra Relevant to the infrastructure 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. 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 Feb 15, 2025
@Shourya742 Shourya742 force-pushed the 2025-02-15-change-config.toml-to-bootstrap.toml branch 2 times, most recently from 39f2c36 to e4506e0 Compare February 15, 2025 17:47
@rustbot
Copy link
Collaborator

rustbot commented Feb 15, 2025

Some changes occurred in compiler/rustc_codegen_gcc

cc @antoyo, @GuillaumeGomez

Some changes occurred in src/tools/compiletest

cc @jieyouxu

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

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

Some changes occurred to the CTFE machinery

cc @rust-lang/wg-const-eval

triagebot.toml has been modified, there may have been changes to the review queue.

cc @davidtwco, @wesleywiser

These commits modify the Cargo.lock file. Unintentional changes to Cargo.lock can be introduced when switching branches and rebasing PRs.

If this was unintentional then you should revert the changes before this PR is merged.
Otherwise, you can ignore this comment.

This PR modifies tests/run-make/. If this PR is trying to port a Makefile
run-make test to use rmake.rs, please update the
run-make port tracking issue
so we can track our progress. You can either modify the tracking issue
directly, or you can comment on the tracking issue and link this PR.

cc @jieyouxu

Some changes occurred in src/doc/rustc/src/platform-support

cc @Noratrieb

This PR modifies src/bootstrap/defaults.

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

Some changes occurred in src/doc/unstable-book/src/compiler-flags/control-flow-guard.md

cc @rust-lang/project-exploit-mitigations, @rcvalle

Some changes occurred in compiler/rustc_codegen_cranelift

cc @bjorn3

This PR changes how LLVM is built. Consider updating src/bootstrap/download-ci-llvm-stamp.

The Miri subtree was changed

cc @rust-lang/miri

Some changes occurred in src/tools/opt-dist

cc @Kobzol

Some changes occurred to the CTFE / Miri interpreter

cc @rust-lang/miri

The rustc-dev-guide subtree was changed. If this PR only touches the dev guide consider submitting a PR directly to rust-lang/rustc-dev-guide otherwise thank you for updating the dev guide with your changes.

cc @BoxyUwU, @jieyouxu, @Kobzol

Some changes occurred in match checking

cc @Nadrieril

@cuviper
Copy link
Member

cuviper commented Feb 15, 2025

This looks like a rebase gone wild? You might try git rebase -i origin/master and delete everything except your own commits. (Replace origin with whatever you have pointing to rust-lang/rust, if that's different.)

@Shourya742 Shourya742 force-pushed the 2025-02-15-change-config.toml-to-bootstrap.toml branch 2 times, most recently from 3c592fd to 6b86aae Compare February 16, 2025 02:00
@bors
Copy link
Contributor

bors commented Mar 14, 2025

☔ The latest upstream changes (presumably #138506) made this pull request unmergeable. Please resolve the merge conflicts.

@Shourya742 Shourya742 force-pushed the 2025-02-15-change-config.toml-to-bootstrap.toml branch from 1a43176 to ea8b263 Compare March 15, 2025 05:43
@Kobzol
Copy link
Contributor

Kobzol commented Mar 15, 2025

@jieyouxu Could you please take another look once you have time? This PR is very conflict prone and it's not approved right now, so it has to be rebased all the time. Thank you!

@bors
Copy link
Contributor

bors commented Mar 16, 2025

☔ The latest upstream changes (presumably #138548) made this pull request unmergeable. Please resolve the merge conflicts.

@jieyouxu
Copy link
Member

jieyouxu commented Mar 16, 2025

@jieyouxu Could you please take another look once you have time? This PR is very conflict prone and it's not approved right now, so it has to be rebased all the time. Thank you!

Sorry, not really available for reviews on larger PRs until next weekend due to medical reasons.

@Kobzol
Copy link
Contributor

Kobzol commented Mar 16, 2025

Oh, ok! I will take a look then. Get well soon!

@Kobzol
Copy link
Contributor

Kobzol commented Mar 17, 2025

Found some more occurrences of config.toml:

@Shourya742 Shourya742 force-pushed the 2025-02-15-change-config.toml-to-bootstrap.toml branch from ea8b263 to 9ef42ba Compare March 17, 2025 07:31
@Kobzol
Copy link
Contributor

Kobzol commented Mar 17, 2025

@bors r=onur-ozkan,jieyouxu,kobzol

Thank you! Let's see what happens this time.

@bors
Copy link
Contributor

bors commented Mar 17, 2025

📌 Commit 4579615 has been approved by onur-ozkan,jieyouxu,kobzol

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 Mar 17, 2025
@bors
Copy link
Contributor

bors commented Mar 17, 2025

⌛ Testing commit 4579615 with merge 8279176...

@bors
Copy link
Contributor

bors commented Mar 17, 2025

☀️ Test successful - checks-actions
Approved by: onur-ozkan,jieyouxu,kobzol
Pushing 8279176 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Mar 17, 2025
@bors bors merged commit 8279176 into rust-lang:master Mar 17, 2025
7 checks passed
@rustbot rustbot added this to the 1.87.0 milestone Mar 17, 2025
Copy link

This is an experimental post-merge analysis report. You can ignore it.

Post-merge report

Comparing 9c67cec (base) -> 8279176 (this PR)

Test differences

No test diffs found

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (8279176): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

Instruction count

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

Max RSS (memory usage)

Results (primary 3.3%, secondary 6.4%)

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)
3.3% [3.3%, 3.3%] 1
Regressions ❌
(secondary)
6.4% [6.4%, 6.4%] 1
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 3.3% [3.3%, 3.3%] 1

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: 774.895s -> 775.979s (0.14%)
Artifact size: 365.10 MiB -> 365.10 MiB (-0.00%)

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Mar 18, 2025
…youxu

Leave a breadcrumb towards bootstrap config documentation in `bootstrap.toml`

I was curious as to the possible bootstrap options I can put in config.toml, but had some trouble figuring it out. There is no obvious documentation in `config.toml` (obviously), the documentation in src/bootstrap/defaults is *nice*, but also rather sparse, by design.
I had to dive into the parsing code, and stuble upon [a very helpful doc comment](https://github.com/rust-lang/rust/blob/30f168ef811aec63124eac677e14699baa9395bd/src/bootstrap/src/core/config/config.rs#L181) there to realize that `config.example.toml` *exists*, and that it does, indeed, answer all of my questions.

So I figured it might be worth making this journey a bit easier for future contributors and add mention the `config.example.toml` directly in `config.toml`.

Now, since rust-lang#137081 is in-flight which would rename `config(.example)?.toml` to `bootstrap(.example)?.toml`, I figure it's better to wait until that one lands, and submit the "new", "correct" filename upfront, instead of landing `config.toml` now and updating it to `boostrap.toml` later.

`@rustbot` blocked rust-lang#137081
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-compiletest Area: The compiletest test runner A-meta Area: Issues & PRs about the rust-lang/rust repository itself A-run-make Area: port run-make Makefiles to rmake.rs A-rustc-dev-guide Area: rustc-dev-guide A-testsuite Area: The testsuite used to check the correctness of rustc merged-by-bors This PR was explicitly merged by bors. PG-exploit-mitigations Project group: Exploit mitigations 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. T-release Relevant to the release subteam, 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.

rename config.toml to bootstrap.toml