Skip to content

Commit e50460b

Browse files
authored
Unrolled build for #146032
Rollup merge of #146032 - heiher:loong64-none-no-lsx, r=lqd Explicity disable LSX feature for `loongarch64-unknown-none` target The `loongarch64-unknown-none` target is a bare-metal target with hardware floating-point support and should not enable SIMD extensions by default. However, LLVM's LoongArch64 backend enables LSX implicitly, inadvertently activating SIMD instructions for this target. This patch explicitly disable LSX feature to prevent unintended SIMD usage.
2 parents 51ff895 + 0b1bc65 commit e50460b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_target/src/spec/targets/loongarch64_unknown_none.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ pub(crate) fn target() -> Target {
1717
arch: "loongarch64".into(),
1818
options: TargetOptions {
1919
cpu: "generic".into(),
20-
features: "+f,+d".into(),
20+
features: "+f,+d,-lsx".into(),
2121
linker_flavor: LinkerFlavor::Gnu(Cc::No, Lld::Yes),
2222
linker: Some("rust-lld".into()),
2323
llvm_abiname: "lp64d".into(),

0 commit comments

Comments
 (0)