Skip to content

Commit 5437b87

Browse files
committed
Auto merge of rust-lang#135015 - heiher:stabilize-loongarch-target-features, r=Amanieu
Partially stabilize LoongArch target features Stabilization PR for the LoongArch target features. This PR stabilizes some of the target features tracked by rust-lang#44839. Specifically, this PR stabilizes the following target features: * f * d * frecipe * lasx * lbt * lsx * lvz Docs PR: rust-lang/reference#1707 r? `@Amanieu`
2 parents dcecb99 + 4a662c2 commit 5437b87

File tree

3 files changed

+9
-13
lines changed

3 files changed

+9
-13
lines changed

compiler/rustc_target/src/target_features.rs

+7-7
Original file line numberDiff line numberDiff line change
@@ -693,17 +693,17 @@ static CSKY_FEATURES: &[(&str, Stability, ImpliedFeatures)] = &[
693693

694694
static LOONGARCH_FEATURES: &[(&str, Stability, ImpliedFeatures)] = &[
695695
// tidy-alphabetical-start
696-
("d", Unstable(sym::loongarch_target_feature), &["f"]),
696+
("d", Stable, &["f"]),
697697
("div32", Unstable(sym::loongarch_target_feature), &[]),
698-
("f", Unstable(sym::loongarch_target_feature), &[]),
699-
("frecipe", Unstable(sym::loongarch_target_feature), &[]),
698+
("f", Stable, &[]),
699+
("frecipe", Stable, &[]),
700700
("lam-bh", Unstable(sym::loongarch_target_feature), &[]),
701701
("lamcas", Unstable(sym::loongarch_target_feature), &[]),
702-
("lasx", Unstable(sym::loongarch_target_feature), &["lsx"]),
703-
("lbt", Unstable(sym::loongarch_target_feature), &[]),
702+
("lasx", Stable, &["lsx"]),
703+
("lbt", Stable, &[]),
704704
("ld-seq-sa", Unstable(sym::loongarch_target_feature), &[]),
705-
("lsx", Unstable(sym::loongarch_target_feature), &["d"]),
706-
("lvz", Unstable(sym::loongarch_target_feature), &[]),
705+
("lsx", Stable, &["d"]),
706+
("lvz", Stable, &[]),
707707
("relax", Unstable(sym::loongarch_target_feature), &[]),
708708
("scq", Unstable(sym::loongarch_target_feature), &[]),
709709
("ual", Unstable(sym::loongarch_target_feature), &[]),

tests/ui/target-feature/abi-required-target-feature-flag-disable.loongarch.stderr

+1-5
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,5 @@ warning: target feature `d` must be enabled to ensure that the ABI of the curren
33
= note: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
44
= note: for more information, see issue #116344 <https://github.com/rust-lang/rust/issues/116344>
55

6-
warning: unstable feature specified for `-Ctarget-feature`: `d`
7-
|
8-
= note: this feature is not stably supported; its behavior can change in the future
9-
10-
warning: 2 warnings emitted
6+
warning: 1 warning emitted
117

tests/ui/target-feature/abi-required-target-feature-flag-disable.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@
2424
pub trait Sized {}
2525

2626
//~? WARN must be enabled to ensure that the ABI of the current target can be implemented correctly
27-
//[x86,riscv,loongarch]~? WARN unstable feature specified for `-Ctarget-feature`
27+
//[x86,riscv]~? WARN unstable feature specified for `-Ctarget-feature`

0 commit comments

Comments
 (0)