Skip to content

Update to LLVM 21 #143684

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

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

Update to LLVM 21 #143684

wants to merge 5 commits into from

Conversation

nikic
Copy link
Contributor

@nikic nikic commented Jul 9, 2025

@rustbot rustbot added 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. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Jul 9, 2025
@rustbot
Copy link
Collaborator

rustbot commented Jul 9, 2025

These commits modify compiler targets.
(See the Target Tier Policy.)

@nikic
Copy link
Contributor Author

nikic commented Jul 9, 2025

@bors2 try @rust-timer queue

@rust-timer

This comment has been minimized.

rust-bors bot added a commit that referenced this pull request Jul 9, 2025
Update to LLVM 21

r? `@ghost`
@rust-bors
Copy link

rust-bors bot commented Jul 9, 2025

⌛ Trying commit ebb63b9 with merge c3e645b

To cancel the try build, run the command @bors2 try cancel.

@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Jul 9, 2025
@rust-log-analyzer

This comment has been minimized.

@rust-bors
Copy link

rust-bors bot commented Jul 9, 2025

💔 Test failed

@nikic
Copy link
Contributor Author

nikic commented Jul 9, 2025

Noooo, a crash while profiling with the bolt instrumentation.

    process didn't exit successfully: `/tmp/tmp-multistage/opt-artifacts/rustc-perf/target/debug/rustc-fake --crate-name regex_automata --edition=2021 /cargo/registry/src/index.crates.io-1949cf8c6b5b557f/regex-automata-0.4.9/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C embed-bitcode=no --cfg 'feature="alloc"' --cfg 'feature="dfa-onepass"' --cfg 'feature="dfa-search"' --cfg 'feature="hybrid"' --cfg 'feature="meta"' --cfg 'feature="nfa"' --cfg 'feature="nfa-backtrack"' --cfg 'feature="nfa-pikevm"' --cfg 'feature="nfa-thompson"' --cfg 'feature="perf"' --cfg 'feature="perf-inline"' --cfg 'feature="perf-literal"' --cfg 'feature="perf-literal-multisubstring"' --cfg 'feature="perf-literal-substring"' --cfg 'feature="std"' --cfg 'feature="syntax"' --cfg 'feature="unicode"' --cfg 'feature="unicode-age"' --cfg 'feature="unicode-bool"' --cfg 'feature="unicode-case"' --cfg 'feature="unicode-gencat"' --cfg 'feature="unicode-perl"' --cfg 'feature="unicode-script"' --cfg 'feature="unicode-segment"' --cfg 'feature="unicode-word-boundary"' --check-cfg 'cfg(docsrs,test)' --check-cfg 'cfg(feature, values("alloc", "default", "dfa", "dfa-build", "dfa-onepass", "dfa-search", "hybrid", "internal-instrument", "internal-instrument-pikevm", "logging", "meta", "nfa", "nfa-backtrack", "nfa-pikevm", "nfa-thompson", "perf", "perf-inline", "perf-literal", "perf-literal-multisubstring", "perf-literal-substring", "std", "syntax", "unicode", "unicode-age", "unicode-bool", "unicode-case", "unicode-gencat", "unicode-perl", "unicode-script", "unicode-segment", "unicode-word-boundary"))' -C metadata=29004f3d2c23a6dc -C extra-filename=-acaa9aabb4aa769d --out-dir /tmp/.tmpSoAMdr/target/release/deps -C linker=clang -C strip=debuginfo -L dependency=/tmp/.tmpSoAMdr/target/release/deps --extern aho_corasick=/tmp/.tmpSoAMdr/target/release/deps/libaho_corasick-f3f82c9a60cf08f9.rmeta --extern memchr=/tmp/.tmpSoAMdr/target/release/deps/libmemchr-e5f42c55eae6f759.rmeta --extern regex_syntax=/tmp/.tmpSoAMdr/target/release/deps/libregex_syntax-7bce46b340cd2bfa.rmeta --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)

@rust-log-analyzer

This comment has been minimized.

@Kobzol
Copy link
Member

Kobzol commented Jul 9, 2025

Noooo, a crash while profiling with the bolt instrumentation.

    process didn't exit successfully: `/tmp/tmp-multistage/opt-artifacts/rustc-perf/target/debug/rustc-fake --crate-name regex_automata --edition=2021 /cargo/registry/src/index.crates.io-1949cf8c6b5b557f/regex-automata-0.4.9/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C embed-bitcode=no --cfg 'feature="alloc"' --cfg 'feature="dfa-onepass"' --cfg 'feature="dfa-search"' --cfg 'feature="hybrid"' --cfg 'feature="meta"' --cfg 'feature="nfa"' --cfg 'feature="nfa-backtrack"' --cfg 'feature="nfa-pikevm"' --cfg 'feature="nfa-thompson"' --cfg 'feature="perf"' --cfg 'feature="perf-inline"' --cfg 'feature="perf-literal"' --cfg 'feature="perf-literal-multisubstring"' --cfg 'feature="perf-literal-substring"' --cfg 'feature="std"' --cfg 'feature="syntax"' --cfg 'feature="unicode"' --cfg 'feature="unicode-age"' --cfg 'feature="unicode-bool"' --cfg 'feature="unicode-case"' --cfg 'feature="unicode-gencat"' --cfg 'feature="unicode-perl"' --cfg 'feature="unicode-script"' --cfg 'feature="unicode-segment"' --cfg 'feature="unicode-word-boundary"' --check-cfg 'cfg(docsrs,test)' --check-cfg 'cfg(feature, values("alloc", "default", "dfa", "dfa-build", "dfa-onepass", "dfa-search", "hybrid", "internal-instrument", "internal-instrument-pikevm", "logging", "meta", "nfa", "nfa-backtrack", "nfa-pikevm", "nfa-thompson", "perf", "perf-inline", "perf-literal", "perf-literal-multisubstring", "perf-literal-substring", "std", "syntax", "unicode", "unicode-age", "unicode-bool", "unicode-case", "unicode-gencat", "unicode-perl", "unicode-script", "unicode-segment", "unicode-word-boundary"))' -C metadata=29004f3d2c23a6dc -C extra-filename=-acaa9aabb4aa769d --out-dir /tmp/.tmpSoAMdr/target/release/deps -C linker=clang -C strip=debuginfo -L dependency=/tmp/.tmpSoAMdr/target/release/deps --extern aho_corasick=/tmp/.tmpSoAMdr/target/release/deps/libaho_corasick-f3f82c9a60cf08f9.rmeta --extern memchr=/tmp/.tmpSoAMdr/target/release/deps/libmemchr-e5f42c55eae6f759.rmeta --extern regex_syntax=/tmp/.tmpSoAMdr/target/release/deps/libregex_syntax-7bce46b340cd2bfa.rmeta --cap-lints allow` (signal: 11, SIGSEGV: invalid memory reference)

Oh no, the day has finally come 😆

@nikic
Copy link
Contributor Author

nikic commented Jul 9, 2025

llvm/llvm-project#147781 for pr-check-1 assertion failure.

@bors
Copy link
Collaborator

bors commented Jul 10, 2025

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

@nikic
Copy link
Contributor Author

nikic commented Jul 10, 2025

llvm/llvm-project#147935 for armhf-gnu test failure.

@nikic
Copy link
Contributor Author

nikic commented Jul 10, 2025

llvm/llvm-project#139443 for musl build failure.

@nikic
Copy link
Contributor Author

nikic commented Jul 11, 2025

llvm/llvm-project#148207 for x86_64-gnu-nopt assertion failure.

@rustbot
Copy link
Collaborator

rustbot commented Jul 14, 2025

⚠️ Warning ⚠️

  • Some commits in this PR modify submodules.

@rust-log-analyzer

This comment has been minimized.

@nikic
Copy link
Contributor Author

nikic commented Jul 14, 2025

llvm/llvm-project#148607 for the brand new x86_64-gnu-miri build failure...

@bors
Copy link
Collaborator

bors commented Jul 14, 2025

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

@nikic
Copy link
Contributor Author

nikic commented Jul 15, 2025

@bors2 try

I was unable to reproduce the bolt issue locally. Fingers crossed that I just hit a bad commit or something.

rust-bors bot added a commit that referenced this pull request Jul 15, 2025
@rust-bors
Copy link

rust-bors bot commented Jul 15, 2025

⌛ Trying commit b0b9a3c with merge cd80bb6

To cancel the try build, run the command @bors2 try cancel.

@Kobzol
Copy link
Member

Kobzol commented Jul 16, 2025

This entire city must be Purged.

@rust-bors
Copy link

rust-bors bot commented Jul 16, 2025

☀️ Try build successful (CI)
Build commit: f4ce95e (f4ce95eedb14d3c068f7e3f04c61dd62257688a1, parent: f21fbac535ab2c3bc50db20547f4d48477357103)

@nikic
Copy link
Contributor Author

nikic commented Jul 16, 2025

@bors2 try jobs=x86_64-mingw-1,x86_64-mingw-2,dist-i686-mingw,dist-x86_64-mingw,aarch64-msvc-1,aarch64-msvc-2,dist-aarch64-msvc

@rust-bors
Copy link

rust-bors bot commented Jul 16, 2025

⌛ Trying commit 5beee45 with merge ea49c99

To cancel the try build, run the command @bors2 try cancel.

rust-bors bot added a commit that referenced this pull request Jul 16, 2025
Update to LLVM 21

Depends on:
 * [x] llvm/llvm-project#147781
 * [x] llvm/llvm-project#147935
 * [x] llvm/llvm-project#139443
 * [x] llvm/llvm-project#148207
 * [x] llvm/llvm-project#148607
 * [ ] llvm/llvm-project#149046
 * [ ] llvm/llvm-project#149097

r? `@ghost`
try-job: x86_64-mingw-1
try-job: x86_64-mingw-2
try-job: dist-i686-mingw
try-job: dist-x86_64-mingw
try-job: aarch64-msvc-1
try-job: aarch64-msvc-2
try-job: dist-aarch64-msvc
@rust-bors
Copy link

rust-bors bot commented Jul 16, 2025

☀️ Try build successful (CI)
Build commit: ea49c99 (ea49c99ab4204207c1555639677f941e3db7d9f4, parent: 1c6de215099bbe33668de762f9591187f6c25eef)

@nikic
Copy link
Contributor Author

nikic commented Jul 17, 2025

@bors2 try jobs=x86_64-msvc-1,x86_64-msvc-2,i686-msvc-1,i686-msvc-2,x86_64-msvc-ext1,x86_64-msvc-ext2,x86_64-msvc-ext3,dist-x86_64-msvc,dist-i686-msvc,dist-x86_64-msvc-alt

rust-bors bot added a commit that referenced this pull request Jul 17, 2025
Update to LLVM 21

Depends on:
 * [x] llvm/llvm-project#147781
 * [x] llvm/llvm-project#147935
 * [x] llvm/llvm-project#139443
 * [x] llvm/llvm-project#148207
 * [x] llvm/llvm-project#148607
 * [x] llvm/llvm-project#149046
 * [ ] llvm/llvm-project#149097

r? `@ghost`
try-job: x86_64-msvc-1
try-job: x86_64-msvc-2
try-job: i686-msvc-1
try-job: i686-msvc-2
try-job: x86_64-msvc-ext1
try-job: x86_64-msvc-ext2
try-job: x86_64-msvc-ext3
try-job: dist-x86_64-msvc
try-job: dist-i686-msvc
try-job: dist-x86_64-msvc-alt
@rust-bors
Copy link

rust-bors bot commented Jul 17, 2025

⌛ Trying commit cd31920 with merge 84911f9

To cancel the try build, run the command @bors2 try cancel.

@rust-bors
Copy link

rust-bors bot commented Jul 17, 2025

💔 Test failed

@nikic
Copy link
Contributor Author

nikic commented Jul 17, 2025

Looks like x86_64-msvc-1 ran out of disk space :(

In the hope that this may fix the bolt issue.
@rustbot rustbot added A-testsuite Area: The testsuite used to check the correctness of rustc T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. labels Jul 17, 2025
@nikic
Copy link
Contributor Author

nikic commented Jul 17, 2025

@bors2 try

Testing whether updating the host toolchain fixes the bolt issue, though I don't have high hopes...

@rust-bors
Copy link

rust-bors bot commented Jul 17, 2025

⌛ Trying commit ab7d9df with merge 3ad929f

To cancel the try build, run the command @bors2 try cancel.

@rust-bors
Copy link

rust-bors bot commented Jul 17, 2025

☀️ Try build successful (CI)
Build commit: 3ad929f (3ad929f623d4cda65ae0e0dcdb154816042509ea, parent: 8c12d76304fcceaeaad0d67209e5727e94f5f2b8)

@Kobzol
Copy link
Member

Kobzol commented Jul 17, 2025

Since it went through, we might as well:

@rust-timer build 3ad929f

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (3ad929f): comparison URL.

Overall result: ❌✅ regressions and improvements - please read the text below

Benchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf.

Next Steps: If you can justify the regressions found in this try perf run, please do so in sufficient writing along with @rustbot label: +perf-regression-triaged. If not, please fix the regressions and do another perf run. If its results are neutral or positive, the label will be automatically removed.

@bors rollup=never
@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.6% [0.5%, 0.7%] 2
Regressions ❌
(secondary)
2.1% [2.0%, 2.2%] 3
Improvements ✅
(primary)
-1.3% [-23.4%, -0.2%] 254
Improvements ✅
(secondary)
-2.6% [-19.3%, -0.2%] 290
All ❌✅ (primary) -1.3% [-23.4%, 0.7%] 256

Max RSS (memory usage)

Results (primary -2.6%, secondary 2.6%)

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

mean range count
Regressions ❌
(primary)
2.6% [1.2%, 4.6%] 4
Regressions ❌
(secondary)
4.0% [0.9%, 7.6%] 13
Improvements ✅
(primary)
-4.2% [-7.6%, -1.3%] 13
Improvements ✅
(secondary)
-3.8% [-5.4%, -1.7%] 3
All ❌✅ (primary) -2.6% [-7.6%, 4.6%] 17

Cycles

Results (primary 0.3%, secondary -3.8%)

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

mean range count
Regressions ❌
(primary)
1.9% [1.9%, 1.9%] 1
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
-1.3% [-1.3%, -1.3%] 1
Improvements ✅
(secondary)
-3.8% [-12.4%, -1.7%] 36
All ❌✅ (primary) 0.3% [-1.3%, 1.9%] 2

Binary size

Results (primary -0.0%, secondary -0.1%)

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

mean range count
Regressions ❌
(primary)
0.1% [0.0%, 0.2%] 30
Regressions ❌
(secondary)
0.1% [0.0%, 0.2%] 14
Improvements ✅
(primary)
-0.2% [-0.4%, -0.0%] 20
Improvements ✅
(secondary)
-0.2% [-1.0%, -0.1%] 41
All ❌✅ (primary) -0.0% [-0.4%, 0.2%] 50

Bootstrap: 463.461s -> 459.088s (-0.94%)
Artifact size: 374.76 MiB -> 374.77 MiB (0.00%)

@rustbot rustbot added perf-regression Performance regression. and removed S-waiting-on-perf Status: Waiting on a perf run to be completed. labels Jul 17, 2025
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. A-testsuite Area: The testsuite used to check the correctness of rustc perf-regression Performance regression. S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. 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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants