Skip to content

Allow overriding filecheck even if LLVM is built or downloaded - #162328

Merged
rust-bors[bot] merged 2 commits into
rust-lang:mainfrom
Kobzol:bootstrap-filecheck-relax
Sep 7, 2026
Merged

Allow overriding filecheck even if LLVM is built or downloaded#162328
rust-bors[bot] merged 2 commits into
rust-lang:mainfrom
Kobzol:bootstrap-filecheck-relax

Conversation

@Kobzol

@Kobzol Kobzol commented Sep 5, 2026

Copy link
Copy Markdown
Member

@antoyo ran into some issues with this, because he wants to run UI tests using the GCC codegen backend. But the tests still require LLVM FileCheck for checking annotations, so he had to download/build LLVM. But really the thing he wants is just to provide an external FileCheck, and that's it. I don't see why we couldn't allow providing filecheck separately, now that it is an explicit step in bootstrap.

r? jieyouxu

@rustbot

rustbot commented Sep 5, 2026

Copy link
Copy Markdown
Collaborator

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

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

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

@rustbot rustbot added 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 Sep 5, 2026
@rust-log-analyzer

This comment has been minimized.

@jieyouxu jieyouxu left a comment

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.

Yeah, that seems reasonable, thanks. r=me with the lint addressed

View changes since this review

@antoyo

antoyo commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Thanks, this seems to fix the issue.

One thing that would be nice if you could find out how to fix this: the llvm sub-module still seems to be cloned on a gcc-only config.

@Kobzol

Kobzol commented Sep 5, 2026

Copy link
Copy Markdown
Member Author

There are surprisingly many things in bootstrap that want to build LLVM 😆 rust.lld must be set to false. I also pushed a change that avoids checking out LLVM if the backend is not enabled, in the maybe_install_* functions. I'm not sure if it is correct in all situations, but it should no longer check out LLVM for your use-case, and in situations where the LLVM backend is enabled (which is 99% of use-cases), it should behave as before.

@antoyo

antoyo commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Thanks. This seems to fix all my issues.
Hopefully, I can finally do a sync after this is merged.

@rust-log-analyzer

This comment has been minimized.

@Kobzol

Kobzol commented Sep 7, 2026

Copy link
Copy Markdown
Member Author

Hmm, it won't be so easy. Sorry, I will revert the last commit, meaning that LLVM will still be checked out. I need to do more refactorings in bootstrap to feel confident that this change won't break anything (which it just did).

@Kobzol
Kobzol force-pushed the bootstrap-filecheck-relax branch from 0a387fc to a490ea6 Compare September 7, 2026 06:24
@Kobzol

Kobzol commented Sep 7, 2026

Copy link
Copy Markdown
Member Author

@bors r=jieyouxu

Approving what you previously approved, with the lint addressed.

@rust-bors

rust-bors Bot commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

📌 Commit a490ea6 has been approved by jieyouxu

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 Sep 7, 2026
jhpratt added a commit to jhpratt/rust that referenced this pull request Sep 7, 2026
…r=jieyouxu

Allow overriding filecheck even if LLVM is built or downloaded

@antoyo ran into some issues with this, because he wants to run UI tests using the GCC codegen backend. But the tests still require LLVM FileCheck for checking annotations, so he had to download/build LLVM. But really the thing he wants is just to provide an external FileCheck, and that's it. I don't see why we couldn't allow providing filecheck separately, now that it is an explicit step in bootstrap.

r? jieyouxu
jhpratt added a commit to jhpratt/rust that referenced this pull request Sep 7, 2026
…r=jieyouxu

Allow overriding filecheck even if LLVM is built or downloaded

@antoyo ran into some issues with this, because he wants to run UI tests using the GCC codegen backend. But the tests still require LLVM FileCheck for checking annotations, so he had to download/build LLVM. But really the thing he wants is just to provide an external FileCheck, and that's it. I don't see why we couldn't allow providing filecheck separately, now that it is an explicit step in bootstrap.

r? jieyouxu
jhpratt added a commit to jhpratt/rust that referenced this pull request Sep 7, 2026
…r=jieyouxu

Allow overriding filecheck even if LLVM is built or downloaded

@antoyo ran into some issues with this, because he wants to run UI tests using the GCC codegen backend. But the tests still require LLVM FileCheck for checking annotations, so he had to download/build LLVM. But really the thing he wants is just to provide an external FileCheck, and that's it. I don't see why we couldn't allow providing filecheck separately, now that it is an explicit step in bootstrap.

r? jieyouxu
JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Sep 7, 2026
…r=jieyouxu

Allow overriding filecheck even if LLVM is built or downloaded

@antoyo ran into some issues with this, because he wants to run UI tests using the GCC codegen backend. But the tests still require LLVM FileCheck for checking annotations, so he had to download/build LLVM. But really the thing he wants is just to provide an external FileCheck, and that's it. I don't see why we couldn't allow providing filecheck separately, now that it is an explicit step in bootstrap.

r? jieyouxu
rust-bors Bot pushed a commit that referenced this pull request Sep 7, 2026
Rollup of 14 pull requests

Successful merges:

 - #162404 (`rust-analyzer` subtree update)
 - #161624 (diagnostics: Point closure trait errors at captured values)
 - #161697 (make `Complex` ABI-compatible on sparc64 and powerpc64)
 - #162182 (delay unexpected successful goal during ambiguity reporting)
 - #162328 (Allow overriding filecheck even if LLVM is built or downloaded)
 - #162367 (Use `reason` for tracked item diagnostics from `cfg_select!`)
 - #162381 (fix bare urls split text)
 - #162388 (std: fix set_permissions_nofollow on espidf and horizon)
 - #162319 (docs(core): correct ARMv8-M Baseline atomic CAS support)
 - #162341 (add regression test for packus_epi16 issue)
 - #162383 (Add a hint for using `nolimit` to the limiting error message)
 - #162384 (remove EnumSizeOpt)
 - #162390 (remove outdated comment in `UnsafeCell::raw_get` source)
 - #162397 (docs: Ask for ABI documentation in the platform support template)
@rust-bors
rust-bors Bot merged commit 6f615a9 into rust-lang:main Sep 7, 2026
13 checks passed
@rustbot rustbot added this to the 1.100.0 milestone Sep 7, 2026
rust-bors Bot pushed a commit that referenced this pull request Sep 7, 2026
Rollup merge of #162328 - Kobzol:bootstrap-filecheck-relax, r=jieyouxu

Allow overriding filecheck even if LLVM is built or downloaded

@antoyo ran into some issues with this, because he wants to run UI tests using the GCC codegen backend. But the tests still require LLVM FileCheck for checking annotations, so he had to download/build LLVM. But really the thing he wants is just to provide an external FileCheck, and that's it. I don't see why we couldn't allow providing filecheck separately, now that it is an explicit step in bootstrap.

r? jieyouxu
@Kobzol
Kobzol deleted the bootstrap-filecheck-relax branch September 7, 2026 11:30
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.

5 participants