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

rustc 1.82.0 beta SIGILL when building facebookincubator/below #130601

Closed
truboxl opened this issue Sep 20, 2024 · 7 comments
Closed

rustc 1.82.0 beta SIGILL when building facebookincubator/below #130601

truboxl opened this issue Sep 20, 2024 · 7 comments
Labels
A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. C-bug Category: This is a bug. I-crash Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics. regression-from-stable-to-beta Performance or correctness regression from stable to beta.

Comments

@truboxl
Copy link

truboxl commented Sep 20, 2024

Code

I tried this command:

rustup default beta-x86_64-unknown-linux-gnu
git clone https://github.com/facebookincubator/below
cd below
cargo build --release

I expected to see this happen: can build below successfully

Instead, this happened: Illegal instruction, build failed

Version it worked on

It most recently worked on: Rust 1.81.0

Version with regression

rustc --version --verbose:

rustc 1.82.0-beta.3 (4976ae480 2024-09-09)

Backtrace

Backtrace

~/below-0.8.1$ RUST_BACKTRACE=full cargo build --release
warning: unexpected `cfg` condition name: `fbcode_build`
  --> below/btrfs/src/lib.rs:29:11
   |
29 | #[cfg(not(fbcode_build))]
   |           ^^^^^^^^^^^^
   |
   = help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `fmt_debug`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `ub_checks`, `unix`, and `windows`
   = help: consider using a Cargo feature instead
   = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
            [lints.rust]
            unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fbcode_build)'] }
   = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(fbcode_build)");` to the top of the `build.rs`
   = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
   = note: `#[warn(unexpected_cfgs)]` on by default

warning: unexpected `cfg` condition name: `fbcode_build`
  --> below/btrfs/src/lib.rs:31:7
   |
31 | #[cfg(fbcode_build)]
   |       ^^^^^^^^^^^^
   |
   = help: consider using a Cargo feature instead
   = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
            [lints.rust]
            unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fbcode_build)'] }
   = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(fbcode_build)");` to the top of the `build.rs`
   = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition name: `fbcode_build`
  --> below/btrfs/src/btrfs_api/mod.rs:18:7
   |
18 | #[cfg(fbcode_build)]
   |       ^^^^^^^^^^^^
   |
   = help: consider using a Cargo feature instead
   = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
            [lints.rust]
            unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fbcode_build)'] }
   = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(fbcode_build)");` to the top of the `build.rs`
   = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition name: `fbcode_build`
  --> below/btrfs/src/btrfs_api/mod.rs:20:11
   |
20 | #[cfg(not(fbcode_build))]
   |           ^^^^^^^^^^^^
   |
   = help: consider using a Cargo feature instead
   = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
            [lints.rust]
            unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fbcode_build)'] }
   = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(fbcode_build)");` to the top of the `build.rs`
   = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition name: `fbcode_build`
  --> below/btrfs/src/btrfs_api/mod.rs:22:11
   |
22 | #[cfg(not(fbcode_build))]
   |           ^^^^^^^^^^^^
   |
   = help: consider using a Cargo feature instead
   = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
            [lints.rust]
            unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fbcode_build)'] }
   = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(fbcode_build)");` to the top of the `build.rs`
   = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: unexpected `cfg` condition name: `fbcode_build`
  --> below/btrfs/src/btrfs_api/mod.rs:28:11
   |
28 | #[cfg(not(fbcode_build))]
   |           ^^^^^^^^^^^^
   |
   = help: consider using a Cargo feature instead
   = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
            [lints.rust]
            unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fbcode_build)'] }
   = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(fbcode_build)");` to the top of the `build.rs`
   = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

warning: `below-btrfs` (lib) generated 6 warnings
   Compiling below-model v0.8.1 (/home/jylo/below-0.8.1/below/model)
   Compiling libbpf-rs v0.23.0
warning: unexpected `cfg` condition name: `fbcode_build`
   --> below/model/src/collector.rs:122:7
    |
122 | #[cfg(fbcode_build)]
    |       ^^^^^^^^^^^^
    |
    = help: expected names are: `clippy`, `debug_assertions`, `doc`, `docsrs`, `doctest`, `feature`, `fmt_debug`, `miri`, `overflow_checks`, `panic`, `proc_macro`, `relocation_model`, `rustfmt`, `sanitize`, `sanitizer_cfi_generalize_pointers`, `sanitizer_cfi_normalize_integers`, `target_abi`, `target_arch`, `target_endian`, `target_env`, `target_family`, `target_feature`, `target_has_atomic`, `target_has_atomic_equal_alignment`, `target_has_atomic_load_store`, `target_os`, `target_pointer_width`, `target_thread_local`, `target_vendor`, `test`, `ub_checks`, `unix`, and `windows`
    = help: consider using a Cargo feature instead
    = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
             [lints.rust]
             unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fbcode_build)'] }
    = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(fbcode_build)");` to the top of the `build.rs`
    = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration
    = note: `#[warn(unexpected_cfgs)]` on by default

warning: unexpected `cfg` condition name: `fbcode_build`
   --> below/model/src/collector.rs:130:11
    |
130 | #[cfg(not(fbcode_build))]
    |           ^^^^^^^^^^^^
    |
    = help: consider using a Cargo feature instead
    = help: or consider adding in `Cargo.toml` the `check-cfg` lint config for the lint:
             [lints.rust]
             unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fbcode_build)'] }
    = help: or consider adding `println!("cargo::rustc-check-cfg=cfg(fbcode_build)");` to the top of the `build.rs`
    = note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg/cargo-specifics.html> for more information about checking conditional configuration

   Compiling zstd-safe v7.0.0
   Compiling crossbeam-deque v0.8.2
   Compiling toml v0.8.6
   Compiling clap v4.5.4
   Compiling regex v1.9.5
   Compiling memmap2 v0.5.10
   Compiling scroll_derive v0.11.0
   Compiling rayon v1.5.3
   Compiling scroll v0.11.0
   Compiling portable-atomic v1.3.2
   Compiling static_assertions v1.1.0
   Compiling maplit v1.0.2
   Compiling below-store v0.8.1 (/home/jylo/below-0.8.1/below/store)
warning: `below-model` (lib) generated 2 warnings
error: could not compile `below-model` (lib); 2 warnings emitted

Caused by:
  process didn't exit successfully: `/home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/rustc --crate-name below_model --edition=2021 below/model/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=108 --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C embed-bitcode=no --check-cfg 'cfg(docsrs)' --check-cfg 'cfg(feature, values())' -C metadata=0f16c260a49b905d -C extra-filename=-0f16c260a49b905d --out-dir /home/jylo/below-0.8.1/target/release/deps -C strip=debuginfo -L dependency=/home/jylo/below-0.8.1/target/release/deps --extern anyhow=/home/jylo/below-0.8.1/target/release/deps/libanyhow-8878ebe6cc8137c0.rmeta --extern async_trait=/home/jylo/below-0.8.1/target/release/deps/libasync_trait-4ba5a1d3189a1b69.so --extern btrfs=/home/jylo/below-0.8.1/target/release/deps/libbelow_btrfs-adfdcb2e7dad66c7.rmeta --extern common=/home/jylo/below-0.8.1/target/release/deps/libbelow_common-d763762cb18adab4.rmeta --extern ethtool=/home/jylo/below-0.8.1/target/release/deps/libbelow_ethtool-76c44eca04e593b6.rmeta --extern gpu_stats=/home/jylo/below-0.8.1/target/release/deps/libbelow_gpu_stats-84b6025c4b8fc5a2.rmeta --extern below_derive=/home/jylo/below-0.8.1/target/release/deps/libbelow_derive-edbdbdcb3de58f46.so --extern cgroupfs=/home/jylo/below-0.8.1/target/release/deps/libcgroupfs-b6edb6c79f113d23.rmeta --extern enum_iterator=/home/jylo/below-0.8.1/target/release/deps/libenum_iterator-3510f902b83f0d7d.rmeta --extern procfs=/home/jylo/below-0.8.1/target/release/deps/libfb_procfs-c1e590b1885e1c10.rmeta --extern hostname=/home/jylo/below-0.8.1/target/release/deps/libhostname-7a22f0ab92aa3fc1.rmeta --extern os_info=/home/jylo/below-0.8.1/target/release/deps/libos_info-394a55b8e0568c0e.rmeta --extern regex=/home/jylo/below-0.8.1/target/release/deps/libregex-c4d3fb13176368de.rmeta --extern resctrlfs=/home/jylo/below-0.8.1/target/release/deps/libresctrlfs-bae45f43d219fcbc.rmeta --extern serde=/home/jylo/below-0.8.1/target/release/deps/libserde-b74aae5554fddc38.rmeta --extern serde_json=/home/jylo/below-0.8.1/target/release/deps/libserde_json-052c7b034969358a.rmeta --extern slog=/home/jylo/below-0.8.1/target/release/deps/libslog-cc6ea4232d0d4a1a.rmeta` (signal: 4, SIGILL: illegal instruction)
warning: build failed, waiting for other jobs to finish...

gdb

logging debugredirect:  off: Debug output will go to both the screen and the log file.
logging enabled:  on: Logging is enabled.
logging file:  The current logfile is "gdb.txt".
logging overwrite:  off: Logging appends to the log file.
logging redirect:  off: Output will go to both the screen and the log file.
Starting program: /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/rustc --crate-name below_model --edition=2021 below/model/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --diagnostic-width=108 --crate-type lib --emit=dep-info,metadata,link -C opt-level=3 -C embed-bitcode=no --check-cfg cfg\(docsrs\) --check-cfg cfg\(feature,\ values\(\)\) -C metadata=0f16c260a49b905d -C extra-filename=-0f16c260a49b905d --out-dir /home/jylo/below-0.8.1/target/release/deps -C strip=debuginfo -L dependency=/home/jylo/below-0.8.1/target/release/deps --extern anyhow=/home/jylo/below-0.8.1/target/release/deps/libanyhow-8878ebe6cc8137c0.rmeta --extern async_trait=/home/jylo/below-0.8.1/target/release/deps/libasync_trait-4ba5a1d3189a1b69.so --extern btrfs=/home/jylo/below-0.8.1/target/release/deps/libbelow_btrfs-adfdcb2e7dad66c7.rmeta --extern common=/home/jylo/below-0.8.1/target/release/deps/libbelow_common-d763762cb18adab4.rmeta --extern ethtool=/home/jylo/below-0.8.1/target/release/deps/libbelow_ethtool-76c44eca04e593b6.rmeta --extern gpu_stats=/home/jylo/below-0.8.1/target/release/deps/libbelow_gpu_stats-84b6025c4b8fc5a2.rmeta --extern below_derive=/home/jylo/below-0.8.1/target/release/deps/libbelow_derive-edbdbdcb3de58f46.so --extern cgroupfs=/home/jylo/below-0.8.1/target/release/deps/libcgroupfs-b6edb6c79f113d23.rmeta --extern enum_iterator=/home/jylo/below-0.8.1/target/release/deps/libenum_iterator-3510f902b83f0d7d.rmeta --extern procfs=/home/jylo/below-0.8.1/target/release/deps/libfb_procfs-c1e590b1885e1c10.rmeta --extern hostname=/home/jylo/below-0.8.1/target/release/deps/libhostname-7a22f0ab92aa3fc1.rmeta --extern os_info=/home/jylo/below-0.8.1/target/release/deps/libos_info-394a55b8e0568c0e.rmeta --extern regex=/home/jylo/below-0.8.1/target/release/deps/libregex-c4d3fb13176368de.rmeta --extern resctrlfs=/home/jylo/below-0.8.1/target/release/deps/libresctrlfs-bae45f43d219fcbc.rmeta --extern serde=/home/jylo/below-0.8.1/target/release/deps/libserde-b74aae5554fddc38.rmeta --extern serde_json=/home/jylo/below-0.8.1/target/release/deps/libserde_json-052c7b034969358a.rmeta --extern slog=/home/jylo/below-0.8.1/target/release/deps/libslog-cc6ea4232d0d4a1a.rmeta
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffe89ff640 (LWP 18795)]
[New Thread 0x7fffe83ff640 (LWP 18796)]
[New Thread 0x7fffcb151640 (LWP 18797)]
[New Thread 0x7fffcaf50640 (LWP 18798)]
[New Thread 0x7fffc73ff640 (LWP 18799)]
[New Thread 0x7fffc6bff640 (LWP 18800)]
[New Thread 0x7fffc4cff640 (LWP 18801)]
[New Thread 0x7fffc45ff640 (LWP 18802)]
[New Thread 0x7fffc3bfe640 (LWP 18803)]
[New Thread 0x7fffc33ff640 (LWP 18804)]
[Thread 0x7fffc6bff640 (LWP 18800) exited]
[New Thread 0x7fffc6bff640 (LWP 18805)]
[New Thread 0x7fffc2c7e640 (LWP 18806)]
[New Thread 0x7fffbe67f640 (LWP 18807)]
[New Thread 0x7fffbdefe640 (LWP 18808)]
[New Thread 0x7fffbd97d640 (LWP 18809)]
[Thread 0x7fffc45ff640 (LWP 18802) exited]
[New Thread 0x7fffc45ff640 (LWP 18810)]
[New Thread 0x7fffbce7c640 (LWP 18811)]
[New Thread 0x7fffbc57b640 (LWP 18812)]
[New Thread 0x7fffbbffa640 (LWP 18813)]
[Thread 0x7fffc2c7e640 (LWP 18806) exited]
[Thread 0x7fffc33ff640 (LWP 18804) exited]
[New Thread 0x7fffc33ff640 (LWP 18814)]
[Thread 0x7fffc3bfe640 (LWP 18803) exited]
[Thread 0x7fffbd97d640 (LWP 18809) exited]
[Thread 0x7fffc45ff640 (LWP 18810) exited]
[Thread 0x7fffc33ff640 (LWP 18814) exited]
[Thread 0x7fffc6bff640 (LWP 18805) exited]
[Thread 0x7fffbc57b640 (LWP 18812) exited]
[Thread 0x7fffbbffa640 (LWP 18813) exited]
[Thread 0x7fffbe67f640 (LWP 18807) exited]
[Thread 0x7fffbdefe640 (LWP 18808) exited]
[Thread 0x7fffbce7c640 (LWP 18811) exited]
[Thread 0x7fffc73ff640 (LWP 18799) exited]
[Thread 0x7fffc4cff640 (LWP 18801) exited]
[New Thread 0x7fffc4cff640 (LWP 18815)]
[New Thread 0x7fffc73ff640 (LWP 18816)]
[New Thread 0x7fffbce7c640 (LWP 18817)]
[New Thread 0x7fffbdefe640 (LWP 18818)]
[New Thread 0x7fffbe67f640 (LWP 18819)]
[New Thread 0x7fffbbffa640 (LWP 18820)]
[New Thread 0x7fffbc57b640 (LWP 18821)]
[New Thread 0x7fffc6bff640 (LWP 18822)]
[New Thread 0x7fffc33ff640 (LWP 18823)]
[New Thread 0x7fffc45ff640 (LWP 18824)]
[New Thread 0x7fffbd97d640 (LWP 18825)]
[New Thread 0x7fffc3bfe640 (LWP 18826)]
[New Thread 0x7fffc2c7e640 (LWP 18827)]
[New Thread 0x7fffe45ff640 (LWP 18828)]
[New Thread 0x7fffe43fe640 (LWP 18829)]
[New Thread 0x7fffe3dfd640 (LWP 18830)]

Thread 32 "lto cgu.07" received signal SIGILL, Illegal instruction.
[Switching to Thread 0x7fffbd97d640 (LWP 18825)]
0x00007fffef2027d4 in llvm::DataLayout::getTypeSizeInBits(llvm::Type*) const () from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#0  0x00007fffef2027d4 in llvm::DataLayout::getTypeSizeInBits(llvm::Type*) const ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#1  0x00007ffff053da58 in bool __gnu_cxx::__ops::_Iter_negate<llvm::slpvectorizer::BoUpSLP::computeMinimumValueSizes()::$_1::operator()(llvm::slpvectorizer::BoUpSLP::TreeEntry const&, bool, bool, unsigned int, unsigned int, bool, bool) const::{lambda(llvm::Value*)#1}>::operator()<llvm::Value* const*>(llvm::Value* const*) [clone .cold] ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#2  0x00007fffef90f687 in llvm::SLPVectorizerPass::vectorizeStores(llvm::ArrayRef<llvm::StoreInst*>, llvm::slpvectorizer::BoUpSLP&, llvm::DenseSet<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, llvm::DenseMapInfo<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, void> >&)::$_0::operator()(std::set<std::pair<unsigned int, int>, llvm::SLPVectorizerPass::vectorizeStores(llvm::ArrayRef<llvm::StoreInst*>, llvm::slpvectorizer::BoUpSLP&, llvm::DenseSet<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, llvm::DenseMapInfo<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, void> >&)::StoreDistCompare, std::allocator<std::pair<unsigned int, int> > > const&) const ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#3  0x00007fffef8f9465 in llvm::SLPVectorizerPass::vectorizeStores(llvm::ArrayRef<llvm::StoreInst*>, llvm::slpvectorizer::BoUpSLP&, llvm::DenseSet<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, llvm::DenseMapInfo<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, void> >&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#4  0x00007fffef760129 in llvm::SLPVectorizerPass::vectorizeStoreChains(llvm::slpvectorizer::BoUpSLP&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#5  0x00007fffef936043 in llvm::SLPVectorizerPass::runImpl(llvm::Function&, llvm::ScalarEvolution*, llvm::TargetTransformInfo*, llvm::TargetLibraryInfo*, llvm::AAResults*, llvm::LoopInfo*, llvm::DominatorTree*, llvm::AssumptionCache*, llvm::DemandedBits*, llvm::OptimizationRemarkEmitter*) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#6  0x00007fffef934a4a in llvm::SLPVectorizerPass::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#7  0x00007fffef93488d in llvm::detail::PassModel<llvm::Function, llvm::SLPVectorizerPass, llvm::AnalysisManager<llvm::Function>>::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#8  0x00007fffef21c491 in llvm::PassManager<llvm::Function, llvm::AnalysisManager<llvm::Function>>::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#9  0x00007fffef214152 in llvm::ModuleToFunctionPassAdaptor::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#10 0x00007fffef213dd9 in llvm::detail::PassModel<llvm::Module, llvm::ModuleToFunctionPassAdaptor, llvm::AnalysisManager<llvm::Module>>::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#11 0x00007fffef95aaa9 in llvm::PassManager<llvm::Module, llvm::AnalysisManager<llvm::Module>>::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
#12 0x00007ffff69e0f18 in LLVMRustOptimize ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
#13 0x00007ffff69e2daf in rustc_codegen_llvm::back::write::llvm_optimize ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
#14 0x00007ffff69e28d6 in rustc_codegen_llvm::back::lto::run_pass_manager ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
#15 0x00007ffff684d533 in <rustc_codegen_llvm::LlvmCodegenBackend as rustc_codegen_ssa::traits::write::WriteBackendMethods>::optimize_thin ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
#16 0x00007ffff6a8e1b6 in std::sys::backtrace::__rust_begin_short_backtrace::<<rustc_codegen_llvm::LlvmCodegenBackend as rustc_codegen_ssa::traits::backend::ExtraBackendMethods>::spawn_named_thread<rustc_codegen_ssa::back::write::spawn_work<rustc_codegen_llvm::LlvmCodegenBackend>::{closure#0}, ()>::{closure#0}, ()> ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
#17 0x00007ffff6a8d7a1 in <<std::thread::Builder>::spawn_unchecked_<<rustc_codegen_llvm::LlvmCodegenBackend as rustc_codegen_ssa::traits::backend::ExtraBackendMethods>::spawn_named_thread<rustc_codegen_ssa::back::write::spawn_work<rustc_codegen_llvm::LlvmCodegenBackend>::{closure#0}, ()>::{closure#0}, ()>::{closure#1} as core::ops::function::FnOnce<()>>::call_once::{shim:vtable#0} ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
#18 0x00007ffff6a8ccab in std::sys::pal::unix::thread::Thread::new::thread_start ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
#19 0x00007ffff106bac3 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
#20 0x00007ffff10fd850 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
#0  0x00007fffef2027d4 in llvm::DataLayout::getTypeSizeInBits(llvm::Type*) const ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#1  0x00007ffff053da58 in bool __gnu_cxx::__ops::_Iter_negate<llvm::slpvectorizer::BoUpSLP::computeMinimumValueSizes()::$_1::operator()(llvm::slpvectorizer::BoUpSLP::TreeEntry const&, bool, bool, unsigned int, unsigned int, bool, bool) const::{lambda(llvm::Value*)#1}>::operator()<llvm::Value* const*>(llvm::Value* const*) [clone .cold] ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#2  0x00007fffef90f687 in llvm::SLPVectorizerPass::vectorizeStores(llvm::ArrayRef<llvm::StoreInst*>, llvm::slpvectorizer::BoUpSLP&, llvm::DenseSet<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, llvm::DenseMapInfo<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, void> >&)::$_0::operator()(std::set<std::pair<unsigned int, int>, llvm::SLPVectorizerPass::vectorizeStores(llvm::ArrayRef<llvm::StoreInst*>, llvm::slpvectorizer::BoUpSLP&, llvm::DenseSet<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, llvm::DenseMapInfo<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, void> >&)::StoreDistCompare, std::allocator<std::pair<unsigned int, int> > > const&) const ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#3  0x00007fffef8f9465 in llvm::SLPVectorizerPass::vectorizeStores(llvm::ArrayRef<llvm::StoreInst*>, llvm::slpvectorizer::BoUpSLP&, llvm::DenseSet<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, llvm::DenseMapInfo<std::tuple<llvm::Value*, llvm::Value*, llvm::Value*, llvm::Value*, unsigned int>, void> >&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#4  0x00007fffef760129 in llvm::SLPVectorizerPass::vectorizeStoreChains(llvm::slpvectorizer::BoUpSLP&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#5  0x00007fffef936043 in llvm::SLPVectorizerPass::runImpl(llvm::Function&, llvm::ScalarEvolution*, llvm::TargetTransformInfo*, llvm::TargetLibraryInfo*, llvm::AAResults*, llvm::LoopInfo*, llvm::DominatorTree*, llvm::AssumptionCache*, llvm::DemandedBits*, llvm::OptimizationRemarkEmitter*) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#6  0x00007fffef934a4a in llvm::SLPVectorizerPass::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#7  0x00007fffef93488d in llvm::detail::PassModel<llvm::Function, llvm::SLPVectorizerPass, llvm::AnalysisManager<llvm::Function>>::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#8  0x00007fffef21c491 in llvm::PassManager<llvm::Function, llvm::AnalysisManager<llvm::Function>>::run(llvm::Function&, llvm::AnalysisManager<llvm::Function>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#9  0x00007fffef214152 in llvm::ModuleToFunctionPassAdaptor::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#10 0x00007fffef213dd9 in llvm::detail::PassModel<llvm::Module, llvm::ModuleToFunctionPassAdaptor, llvm::AnalysisManager<llvm::Module>>::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#11 0x00007fffef95aaa9 in llvm::PassManager<llvm::Module, llvm::AnalysisManager<llvm::Module>>::run(llvm::Module&, llvm::AnalysisManager<llvm::Module>&) ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/../lib/libLLVM.so.19.1-rust-1.82.0-beta
No symbol table info available.
#12 0x00007ffff69e0f18 in LLVMRustOptimize ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
No symbol table info available.
#13 0x00007ffff69e2daf in rustc_codegen_llvm::back::write::llvm_optimize ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
No symbol table info available.
#14 0x00007ffff69e28d6 in rustc_codegen_llvm::back::lto::run_pass_manager ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
No symbol table info available.
#15 0x00007ffff684d533 in <rustc_codegen_llvm::LlvmCodegenBackend as rustc_codegen_ssa::traits::write::WriteBackendMethods>::optimize_thin ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
No symbol table info available.
#16 0x00007ffff6a8e1b6 in std::sys::backtrace::__rust_begin_short_backtrace::<<rustc_codegen_llvm::LlvmCodegenBackend as rustc_codegen_ssa::traits::backend::ExtraBackendMethods>::spawn_named_thread<rustc_codegen_ssa::back::write::spawn_work<rustc_codegen_llvm::LlvmCodegenBackend>::{closure#0}, ()>::{closure#0}, ()> ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
No symbol table info available.
#17 0x00007ffff6a8d7a1 in <<std::thread::Builder>::spawn_unchecked_<<rustc_codegen_llvm::LlvmCodegenBackend as rustc_codegen_ssa::traits::backend::ExtraBackendMethods>::spawn_named_thread<rustc_codegen_ssa::back::write::spawn_work<rustc_codegen_llvm::LlvmCodegenBackend>::{closure#0}, ()>::{closure#0}, ()>::{closure#1} as core::ops::function::FnOnce<()>>::call_once::{shim:vtable#0} ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
No symbol table info available.
#18 0x00007ffff6a8ccab in std::sys::pal::unix::thread::Thread::new::thread_start ()
   from /home/jylo/.rustup/toolchains/beta-x86_64-unknown-linux-gnu/bin/../lib/librustc_driver-aae6278cc4b64914.so
No symbol table info available.
#19 0x00007ffff106bac3 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
        ret = <optimized out>
        pd = <optimized out>
        out = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140736598431008, 7409635665587985377, 140736374232640, 
                0, 140737237137360, 140736598431360, -7409781144634270751, -7409632584110580767}, 
              mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, 
              canceltype = 0}}}
        not_first_call = <optimized out>
#20 0x00007ffff10fd850 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
No locals.
@truboxl truboxl added C-bug Category: This is a bug. regression-untriaged Untriaged performance or correctness regression. labels Sep 20, 2024
@rustbot rustbot added I-prioritize Issue: Indicates that prioritization has been requested for this issue. needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. regression-from-stable-to-beta Performance or correctness regression from stable to beta. and removed regression-untriaged Untriaged performance or correctness regression. labels Sep 20, 2024
@jieyouxu jieyouxu added the I-crash Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics. label Sep 20, 2024
@matthiaskrgr matthiaskrgr added the A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. label Sep 20, 2024
@jieyouxu

This comment has been minimized.

@oli-obk oli-obk added the E-needs-bisection Call for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustc label Sep 20, 2024
@truboxl
Copy link
Author

truboxl commented Sep 20, 2024

I think you need to use a newer clang. I use clang-17.

@nikic
Copy link
Contributor

nikic commented Sep 20, 2024

Does this happen on nightly? This looks like the same issue as #129887 to me, which is fixed on nightly, but hasn't been backported to beta yet.

@truboxl
Copy link
Author

truboxl commented Sep 20, 2024

Does this happen on nightly? This looks like the same issue as #129887 to me, which is fixed on nightly, but hasn't been backported to beta yet.

Good news! I am able to build with rust nightly:

rustc 1.83.0-nightly (506f22b46 2024-09-19)
binary: rustc
commit-hash: 506f22b4663f3e756e1e6a4f66c6309fdc00819c
commit-date: 2024-09-19
host: x86_64-unknown-linux-gnu
release: 1.83.0-nightly
LLVM version: 19.1.0

Just that I need to delete that one line in ahash that broke the build:

   Compiling ahash v0.8.0
   Compiling xi-unicode v0.3.0
error[E0635]: unknown feature `stdsimd`
  --> /home/jylo/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ahash-0.8.0/src/lib.rs:48:42
   |
48 | #![cfg_attr(feature = "stdsimd", feature(stdsimd))]
   |                                          ^^^^^^^

   Compiling slog v2.7.0
For more information about this error, try `rustc --explain E0635`.
error: could not compile `ahash` (lib) due to 1 previous error
warning: build failed, waiting for other jobs to finish...

@Noratrieb Noratrieb removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Sep 20, 2024
@apiraino
Copy link
Contributor

Does this happen on nightly? This looks like the same issue as #129887 to me, which is fixed on nightly, but hasn't been backported to beta yet.

If I understand correctly, backporting #130212 will also fix this one

@rustbot label -I-prioritize

@rustbot rustbot removed the I-prioritize Issue: Indicates that prioritization has been requested for this issue. label Sep 25, 2024
@dianqk
Copy link
Member

dianqk commented Oct 5, 2024

The beta version should have already fixed this issue.

@truboxl
Copy link
Author

truboxl commented Oct 7, 2024

Sorry for the late reply. Yes I can confirm the latest beta no longer can reproduce the issue and can build below successfully.

rustc 1.82.0-beta.5 (6a3b69c6b 2024-09-27)
binary: rustc
commit-hash: 6a3b69c6b0529151da5fb4568961519a80adccf9
commit-date: 2024-09-27
host: x86_64-unknown-linux-gnu
release: 1.82.0-beta.5
LLVM version: 19.1.0

@truboxl truboxl closed this as completed Oct 7, 2024
@jieyouxu jieyouxu removed the E-needs-bisection Call for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustc label Oct 7, 2024
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. C-bug Category: This is a bug. I-crash Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics. regression-from-stable-to-beta Performance or correctness regression from stable to beta.
Projects
None yet
Development

No branches or pull requests

9 participants