-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
[LoongArch] dead loop after nightly-2024-02-12 #121289
Comments
@rustbot label O-loongarch |
That would be due to the LLVM 18 upgrade. |
Yeah. It seems that the CI loongarch64-unknown-linux-gnu ld does not handle
|
There is no version of crosstool-ng that supports |
Oooops. Is this communicated with crosstool-ng maintainers? |
But maybe crosstool-ng maintainers can't act as well due to the incompatibility between GCC 13.2 and Binutils 2.42 (loongson-community/discussions#41) :(. I'm not sure how to fix such an incompatibility... |
Not yet. binutils 2.42 in progress: crosstool-ng/crosstool-ng#2095 |
…strieb target: Revert default to the medium code model on LoongArch targets This reverts commit 35dad14. Fixes rust-lang#121289
…strieb target: Revert default to the medium code model on LoongArch targets This reverts commit 35dad14. Fixes rust-lang#121289
Rollup merge of rust-lang#121291 - heiher:revert-medium-cmodel, r=Nilstrieb target: Revert default to the medium code model on LoongArch targets This reverts commit 35dad14. Fixes rust-lang#121289
The current cross-compilation toolchain for the LoongArch64 target consists of GCC 13.2.0, Binutils 2.40, and Glibc 2.36. However, Binutils 2.40 has known issues that in broken binaries without any error reports: - rust-lang#121289 - cross-rs/cross#1538 This patch upgrades the cross-compilation toolchain for the LoongArch64 target to resolve these issues. - GCC: 13.2.0 -> 14.2.0 - Binutils: 2.40 -> 2.42 The new binaries remain compatible with the existing GCC 13.2.0/Glibc 2.36 distribution, and no issues have been identified.
… r=<try> Update `crosstool-ng` for loongarch64 The current cross-compilation toolchain for the LoongArch64 target consists of GCC 13.2.0, Binutils 2.40, and Glibc 2.36. However, Binutils 2.40 has known issues that in broken binaries without any error reports: - rust-lang#121289 - cross-rs/cross#1538 This patch upgrades the cross-compilation toolchain for the LoongArch64 target to resolve these issues. - GCC: 13.2.0 -> 14.2.0 - Binutils: 2.40 -> 2.42 The new binaries remain compatible with the existing GCC 13.2.0/Glibc 2.36 distribution, and no issues have been identified. try-job: dist-loongarch64-linux
…4, r=Mark-Simulacrum Update `crosstool-ng` for loongarch64 The current cross-compilation toolchain for the LoongArch64 target consists of GCC 13.2.0, Binutils 2.40, and Glibc 2.36. However, Binutils 2.40 has known issues that in broken binaries without any error reports: - rust-lang#121289 - cross-rs/cross#1538 This patch upgrades the cross-compilation toolchain for the LoongArch64 target to resolve these issues. - GCC: 13.2.0 -> 14.2.0 - Binutils: 2.40 -> 2.42 The new binaries remain compatible with the existing GCC 13.2.0/Glibc 2.36 distribution, and no issues have been identified. try-job: dist-loongarch64-linux
Rollup merge of rust-lang#129048 - heiher:update-crosstool-loongarch64, r=Mark-Simulacrum Update `crosstool-ng` for loongarch64 The current cross-compilation toolchain for the LoongArch64 target consists of GCC 13.2.0, Binutils 2.40, and Glibc 2.36. However, Binutils 2.40 has known issues that in broken binaries without any error reports: - rust-lang#121289 - cross-rs/cross#1538 This patch upgrades the cross-compilation toolchain for the LoongArch64 target to resolve these issues. - GCC: 13.2.0 -> 14.2.0 - Binutils: 2.40 -> 2.42 The new binaries remain compatible with the existing GCC 13.2.0/Glibc 2.36 distribution, and no issues have been identified. try-job: dist-loongarch64-linux
…-Simulacrum Update `crosstool-ng` for loongarch64 The current cross-compilation toolchain for the LoongArch64 target consists of GCC 13.2.0, Binutils 2.40, and Glibc 2.36. However, Binutils 2.40 has known issues that in broken binaries without any error reports: - rust-lang/rust#121289 - cross-rs/cross#1538 This patch upgrades the cross-compilation toolchain for the LoongArch64 target to resolve these issues. - GCC: 13.2.0 -> 14.2.0 - Binutils: 2.40 -> 2.42 The new binaries remain compatible with the existing GCC 13.2.0/Glibc 2.36 distribution, and no issues have been identified. try-job: dist-loongarch64-linux
…iler-errors target: default to the medium code model on LoongArch targets The Rust LoongArch targets have been using the default LLVM code model so far, which is "small" in LLVM-speak and "normal" in LoongArch-speak. As described in the "Code Model" section of LoongArch ELF psABI spec v20231219 [1], one can only make function calls as far as ±128MiB with the "normal" code model; this is insufficient for very large software containing Rust components that needs to be linked into the big text section, such as Chromium. Because: * we do not want to ask users to recompile std if they are to build such software, * objects compiled with larger code models can be linked with those with smaller code models without problems, and * the "medium" code model is comparable to the "small"/"normal" one performance-wise (same data access pattern; each function call becomes 2-insn long and indirect, but this may be relaxed back into the direct 1-insn form in a future LLVM version), but is able to perform function calls within ±128GiB, it is better to just switch the targets to the "medium" code model, which is also "medium" in LLVM-speak. Relands [2]: rust-lang#120661 [1]: https://github.com/loongson/la-abi-specs/blob/v2.30/laelf.adoc#code-models [2]: rust-lang#121289 (comment)
Rollup merge of rust-lang#130266 - heiher:loong-medium-cmodel, r=compiler-errors target: default to the medium code model on LoongArch targets The Rust LoongArch targets have been using the default LLVM code model so far, which is "small" in LLVM-speak and "normal" in LoongArch-speak. As described in the "Code Model" section of LoongArch ELF psABI spec v20231219 [1], one can only make function calls as far as ±128MiB with the "normal" code model; this is insufficient for very large software containing Rust components that needs to be linked into the big text section, such as Chromium. Because: * we do not want to ask users to recompile std if they are to build such software, * objects compiled with larger code models can be linked with those with smaller code models without problems, and * the "medium" code model is comparable to the "small"/"normal" one performance-wise (same data access pattern; each function call becomes 2-insn long and indirect, but this may be relaxed back into the direct 1-insn form in a future LLVM version), but is able to perform function calls within ±128GiB, it is better to just switch the targets to the "medium" code model, which is also "medium" in LLVM-speak. Relands [2]: rust-lang#120661 [1]: https://github.com/loongson/la-abi-specs/blob/v2.30/laelf.adoc#code-models [2]: rust-lang#121289 (comment)
target: default to the medium code model on LoongArch targets The Rust LoongArch targets have been using the default LLVM code model so far, which is "small" in LLVM-speak and "normal" in LoongArch-speak. As described in the "Code Model" section of LoongArch ELF psABI spec v20231219 [1], one can only make function calls as far as ±128MiB with the "normal" code model; this is insufficient for very large software containing Rust components that needs to be linked into the big text section, such as Chromium. Because: * we do not want to ask users to recompile std if they are to build such software, * objects compiled with larger code models can be linked with those with smaller code models without problems, and * the "medium" code model is comparable to the "small"/"normal" one performance-wise (same data access pattern; each function call becomes 2-insn long and indirect, but this may be relaxed back into the direct 1-insn form in a future LLVM version), but is able to perform function calls within ±128GiB, it is better to just switch the targets to the "medium" code model, which is also "medium" in LLVM-speak. Relands [2]: #120661 [1]: https://github.com/loongson/la-abi-specs/blob/v2.30/laelf.adoc#code-models [2]: rust-lang/rust#121289 (comment)
Today's nightly is built off of #130312, which contains #130266 and does work:
And the
So this issue is finally resolved. Thanks for everyone involved! |
I tried this code:
I expected to see this happen: outputs version info
Instead, this happened: dead loop in
main
entry function.Meta
rustc --version --verbose
:The text was updated successfully, but these errors were encountered: