Skip to content

Update LLVM submodule to latest release/23.x branch - #161466

Open
alexcrichton wants to merge 1 commit into
rust-lang:mainfrom
alexcrichton:update-llvm
Open

Update LLVM submodule to latest release/23.x branch#161466
alexcrichton wants to merge 1 commit into
rust-lang:mainfrom
alexcrichton:update-llvm

Conversation

@alexcrichton

Copy link
Copy Markdown
Member

This pulls in rust-lang/llvm-project#199 which updates the revision of LLVM 23 to the latest copy of the release branch, just past the rc3 release.

@rustbot rustbot added the A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. label Aug 21, 2026
@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 21, 2026
@rustbot

rustbot commented Aug 21, 2026

Copy link
Copy Markdown
Collaborator

r? @cuviper

rustbot has assigned @cuviper.
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

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: @cuviper

@rustbot

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@Kobzol

Kobzol commented Aug 21, 2026

Copy link
Copy Markdown
Member

Oops, that sounds like a bootstrap bug, possibly caused by some of my recent refactorings. I'll take a look.

@cuviper cuviper 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.

r=me once CI is straightened out.

View changes since this review

@Kobzol

Kobzol commented Aug 21, 2026

Copy link
Copy Markdown
Member

#161475 should hopefully fix this, but I'll have to do some experiments with it first.

@nikic

nikic commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

@bors try @rust-timer queue

This update is expected to have perf impact.

@rust-timer

This comment has been minimized.

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Aug 21, 2026
@rust-bors

This comment has been minimized.

rust-bors Bot pushed a commit that referenced this pull request Aug 21, 2026
Update LLVM submodule to latest `release/23.x` branch
@rust-bors

rust-bors Bot commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

☀️ Try build successful (CI)
Build commit: 0587bd1 (0587bd1ad74de0297e7f5d4272e335a2148c07ed)
Base parent: a872286 (a872286d0a1873caec0291ed4304de3170adbe16)

@rust-timer

This comment has been minimized.

@rust-timer

Copy link
Copy Markdown
Collaborator

Finished benchmarking commit (0587bd1): comparison URL.

Overall result: ✅ improvements - no action needed

Benchmarking means the PR may be perf-sensitive. It's automatically marked not fit for rolling up. Overriding is possible but disadvised: it risks changing compiler perf.

@bors rollup=never rustc-perf
@rustbot label: -S-waiting-on-perf -perf-regression

Instruction count

Our most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-10.7% [-11.7%, -10.2%] 3
All ❌✅ (primary) - - 0

Max RSS (memory usage)

Results (primary 2.6%, secondary 4.1%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

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

Cycles

Results (secondary -4.1%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

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

Binary size

This perf run didn't have relevant results for this metric.

Bootstrap: 468.499s -> 469.706s (0.26%)
Artifact size: 400.07 MiB -> 400.14 MiB (0.02%)

@rustbot rustbot removed the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Aug 21, 2026
@alexcrichton

Copy link
Copy Markdown
Member Author

@Kobzol I'm happy to defer to #161475 as well if it's easiest to land the update there too

@Kobzol

Kobzol commented Aug 22, 2026

Copy link
Copy Markdown
Member

I'd rather land them separately, both in case we'd need to revert that other PR, and also to test that the LLVM check will work in a PR that only updates LLVM (after the fix was already landed).

JonathanBrouwer added a commit to JonathanBrouwer/rust that referenced this pull request Aug 22, 2026
…=jieyouxu

Fix checking of LLVM prebuilt status

This regressed in rust-lang#160916.

I'll start from the end. There was a pre-existing bug (fixed by the second commit of this PR), where if we do `x check library`, we have `builder.kind == Kind::Check`, but we are actually building things (like the compiler) during that bootstrap invocation. But bootstrap was only checking the builder kind before, and in that case it would skip building LLVM, *unless* it was already built locally previously. On PR CI, and perhaps always (because build steps executed during check likely only occur during `x check library`, which requires *building* the compiler anyway), the LLVM was built locally anyway, so this bug was hidden away. This also removes an unnecessary LLVM build when running Clippy on the rustc_private tools.

However, after rust-lang#160916, this was no longer case, because it stopped treating locally built LLVM as being prebuilt (which, in and of itself, is kinda a bug). Because when we check the compiler, we want to avoid building (and checking out!) LLVM. Before rust-lang#160916, bootstrap considered a *previously locally built* LLVM to be available as a prebuilt `llvm-config`, and in that case configured `LLVM_CONFIG` for `rustc_llvm`. Because all PR CI bootstrap invocations that do `check` actually built LLVM prior doing a build, this worked, somehow, but broke after my PR.

Should unblock rust-lang#161466.

r? jieyouxu
rust-bors Bot pushed a commit that referenced this pull request Aug 22, 2026
Rollup merge of #161475 - Kobzol:bootstrap-llvm-check-fix, r=jieyouxu

Fix checking of LLVM prebuilt status

This regressed in #160916.

I'll start from the end. There was a pre-existing bug (fixed by the second commit of this PR), where if we do `x check library`, we have `builder.kind == Kind::Check`, but we are actually building things (like the compiler) during that bootstrap invocation. But bootstrap was only checking the builder kind before, and in that case it would skip building LLVM, *unless* it was already built locally previously. On PR CI, and perhaps always (because build steps executed during check likely only occur during `x check library`, which requires *building* the compiler anyway), the LLVM was built locally anyway, so this bug was hidden away. This also removes an unnecessary LLVM build when running Clippy on the rustc_private tools.

However, after #160916, this was no longer case, because it stopped treating locally built LLVM as being prebuilt (which, in and of itself, is kinda a bug). Because when we check the compiler, we want to avoid building (and checking out!) LLVM. Before #160916, bootstrap considered a *previously locally built* LLVM to be available as a prebuilt `llvm-config`, and in that case configured `LLVM_CONFIG` for `rustc_llvm`. Because all PR CI bootstrap invocations that do `check` actually built LLVM prior doing a build, this worked, somehow, but broke after my PR.

Should unblock #161466.

r? jieyouxu
This pulls in rust-lang/llvm-project#199 which updates the revision of
LLVM 23 to the latest copy of the release branch, just past the rc3 release.
@rustbot

rustbot commented Aug 22, 2026

Copy link
Copy Markdown
Collaborator

This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed.

Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.

@rustbot

rustbot commented Aug 22, 2026

Copy link
Copy Markdown
Collaborator

⚠️ Warning ⚠️

  • Some commits in this PR modify submodules.

    If this was not intentional, see I changed a submodule on accident in the rustc dev guide.

  • There are issue links (such as #123) in the commit messages of the following commits.
    Please move them to the PR description, to avoid spamming the issues with references to the commit, and so this bot can automatically canonicalize them to avoid issues with subtree.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants