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

Disable llvm-bitcode-linker in the default bootstrap profiles #126479

Merged
merged 1 commit into from
Jun 16, 2024

Conversation

Kobzol
Copy link
Contributor

@Kobzol Kobzol commented Jun 14, 2024

I don't think that we really need to enable llvm-bitcode-linker in the default bootstrap profiles, since it seems that it is only useful for running nvptx tests. It should be enabled on CI, which it is, and that should be enough. People can enable it easily locally, if they want.

The linker causes occasionally some rebuild issues (#122491, #126464), but more importantly it is just needless work to build it locally.

I kept it enabled for dist, because it is distributed as a rustup component (for some reason it's not included in extended? not sure).

Fixes: #126464

@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 Jun 14, 2024
@Noratrieb
Copy link
Member

oh, it's only required for nvptx tests? very good to delete that default then, completely wasted time

@Kobzol Kobzol force-pushed the disable-llvm-linker-by-default branch from 12ba73e to 64da5e9 Compare June 14, 2024 13:47
@rustbot rustbot added A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc O-unix Operating system: Unix-like labels Jun 14, 2024
@Kobzol Kobzol marked this pull request as ready for review June 14, 2024 13:47
@rustbot

This comment was marked as outdated.

@rustbot rustbot added has-merge-commits PR has merge commits, merge with caution. S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jun 14, 2024
@rustbot

This comment was marked as outdated.

@Kobzol Kobzol force-pushed the disable-llvm-linker-by-default branch from 64da5e9 to b4df72a Compare June 14, 2024 13:49
@rustbot rustbot removed has-merge-commits PR has merge commits, merge with caution. S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jun 14, 2024
@Kobzol
Copy link
Contributor Author

Kobzol commented Jun 14, 2024

r? @onur-ozkan

@onur-ozkan
Copy link
Member

onur-ozkan commented Jun 15, 2024

Wouldn't this cause some (nvptx) tests to fail?

@Kobzol
Copy link
Contributor Author

Kobzol commented Jun 15, 2024

If yes, then we should configure CI to either enable it for that runner, or skip that test if the linker isn't available.

There are a bunch of tests that need special conditions on CI. nvptx tests should be running on a few dedicated jobs, not necessarily everywhere, and not necessarily locally by default.

PR CI is green, we'd have to take a look at what happens on an auto build. I'll also try to run the tests locally.

@Noratrieb
Copy link
Member

I'd rather have the tests (that I have never run) fail locally (with an error message telling me what to do) than wait the few seconds every time.

@onur-ozkan
Copy link
Member

If yes, then we should configure CI to either enable it for that runner, or skip that test if the linker isn't available.

Yeah, running those tests only if the linker is available would be good solution.

@Kobzol
Copy link
Contributor Author

Kobzol commented Jun 15, 2024

Yeah, running those tests only if the linker is available would be good solution.

That kind of already happens, because you explicitly need to compile LLVM with support for nvptx for these tests to not be ignored, IIRC.

Unless you have objections, I'd r+ this to check if full CI passes.

@bors rollup=never

@onur-ozkan
Copy link
Member

you explicitly need to compile LLVM with support for nvptx for these tests to not be ignored, IIRC.

I think we do that by default when compiling LLVM

#targets = "AArch64;ARM;BPF;Hexagon;LoongArch;MSP430;Mips;NVPTX;PowerPC;RISCV;Sparc;SystemZ;WebAssembly;X86"

@Kobzol
Copy link
Contributor Author

Kobzol commented Jun 15, 2024

If I run the nvpts UI/assembly tests locally, they are ignored though (even if I enable the LLVM bitcode linker) 🤷‍♂️ When using LLVM from CI. I'm not sure what causes them to be ignored then.

In any case, the linker does not seem to be required to run the "default" test suite, therefore I don't see a reason why it should be enabled and compiled by default.

@onur-ozkan
Copy link
Member

If I run the nvpts UI/assembly tests locally, they are ignored though (even if I enable the LLVM bitcode linker) 🤷‍♂️ When using LLVM from CI. I'm not sure what causes them to be ignored then.

Sounds totally broken 😄. Not a blocker for this PR anyway, so let's ship this.

@bors r+

@bors
Copy link
Contributor

bors commented Jun 15, 2024

📌 Commit b4df72a 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 15, 2024
@bors
Copy link
Contributor

bors commented Jun 16, 2024

⌛ Testing commit b4df72a with merge bc3618f...

@bors
Copy link
Contributor

bors commented Jun 16, 2024

☀️ Test successful - checks-actions
Approved by: onur-ozkan
Pushing bc3618f to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jun 16, 2024
@bors bors merged commit bc3618f into rust-lang:master Jun 16, 2024
7 checks passed
@rustbot rustbot added this to the 1.81.0 milestone Jun 16, 2024
@rust-timer
Copy link
Collaborator

Finished benchmarking commit (bc3618f): 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)

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

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: 671.095s -> 670.967s (-0.02%)
Artifact size: 320.43 MiB -> 320.36 MiB (-0.02%)

@Kobzol Kobzol deleted the disable-llvm-linker-by-default branch June 16, 2024 06:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc merged-by-bors This PR was explicitly merged by bors. O-unix Operating system: Unix-like 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
Status: Done
Development

Successfully merging this pull request may close these issues.

Running run-make tests performs unnecessary rebuilds
6 participants