extract s390x vector and friends to their own rust feature

This commit is contained in:
Folkert de Vries 2025-08-20 12:08:27 +02:00
parent 642c19bfc3
commit 0645ac31cb
No known key found for this signature in database
GPG key ID: 1F17F6FFD112B97C
11 changed files with 22 additions and 18 deletions

View file

@ -343,6 +343,7 @@ declare_features! (
(unstable, riscv_target_feature, "1.45.0", Some(44839)),
(unstable, rtm_target_feature, "1.35.0", Some(44839)),
(unstable, s390x_target_feature, "1.82.0", Some(44839)),
(unstable, s390x_target_feature_vector, "CURRENT_RUSTC_VERSION", Some(145649)),
(unstable, sparc_target_feature, "1.84.0", Some(132783)),
(unstable, wasm_target_feature, "1.30.0", Some(44839)),
(unstable, x87_target_feature, "1.85.0", Some(44839)),

View file

@ -2000,6 +2000,7 @@ symbols! {
s,
s390x,
s390x_target_feature,
s390x_target_feature_vector,
safety,
sanitize,
sanitizer_cfi_generalize_pointers,

View file

@ -844,20 +844,20 @@ const IBMZ_FEATURES: &[(&str, Stability, ImpliedFeatures)] = &[
("message-security-assist-extension8", Unstable(sym::s390x_target_feature), &["message-security-assist-extension3"]),
("message-security-assist-extension9", Unstable(sym::s390x_target_feature), &["message-security-assist-extension3", "message-security-assist-extension4"]),
("message-security-assist-extension12", Unstable(sym::s390x_target_feature), &[]),
("miscellaneous-extensions-2", Unstable(sym::s390x_target_feature), &[]),
("miscellaneous-extensions-3", Unstable(sym::s390x_target_feature), &[]),
("miscellaneous-extensions-4", Unstable(sym::s390x_target_feature), &[]),
("nnp-assist", Unstable(sym::s390x_target_feature), &["vector"]),
("miscellaneous-extensions-2", Unstable(sym::s390x_target_feature_vector), &[]),
("miscellaneous-extensions-3", Unstable(sym::s390x_target_feature_vector), &[]),
("miscellaneous-extensions-4", Unstable(sym::s390x_target_feature_vector), &[]),
("nnp-assist", Unstable(sym::s390x_target_feature_vector), &["vector"]),
("soft-float", Forbidden { reason: "currently unsupported ABI-configuration feature" }, &[]),
("transactional-execution", Unstable(sym::s390x_target_feature), &[]),
("vector", Unstable(sym::s390x_target_feature), &[]),
("vector-enhancements-1", Unstable(sym::s390x_target_feature), &["vector"]),
("vector-enhancements-2", Unstable(sym::s390x_target_feature), &["vector-enhancements-1"]),
("vector-enhancements-3", Unstable(sym::s390x_target_feature), &["vector-enhancements-2"]),
("vector-packed-decimal", Unstable(sym::s390x_target_feature), &["vector"]),
("vector-packed-decimal-enhancement", Unstable(sym::s390x_target_feature), &["vector-packed-decimal"]),
("vector-packed-decimal-enhancement-2", Unstable(sym::s390x_target_feature), &["vector-packed-decimal-enhancement"]),
("vector-packed-decimal-enhancement-3", Unstable(sym::s390x_target_feature), &["vector-packed-decimal-enhancement-2"]),
("vector", Unstable(sym::s390x_target_feature_vector), &[]),
("vector-enhancements-1", Unstable(sym::s390x_target_feature_vector), &["vector"]),
("vector-enhancements-2", Unstable(sym::s390x_target_feature_vector), &["vector-enhancements-1"]),
("vector-enhancements-3", Unstable(sym::s390x_target_feature_vector), &["vector-enhancements-2"]),
("vector-packed-decimal", Unstable(sym::s390x_target_feature_vector), &["vector"]),
("vector-packed-decimal-enhancement", Unstable(sym::s390x_target_feature_vector), &["vector-packed-decimal"]),
("vector-packed-decimal-enhancement-2", Unstable(sym::s390x_target_feature_vector), &["vector-packed-decimal-enhancement"]),
("vector-packed-decimal-enhancement-3", Unstable(sym::s390x_target_feature_vector), &["vector-packed-decimal-enhancement-2"]),
// tidy-alphabetical-end
];

View file

@ -204,6 +204,7 @@
#![feature(riscv_target_feature)]
#![feature(rtm_target_feature)]
#![feature(s390x_target_feature)]
#![feature(s390x_target_feature_vector)]
#![feature(wasm_target_feature)]
#![feature(x86_amx_intrinsics)]
// tidy-alphabetical-end

View file

@ -22,7 +22,7 @@
arm_target_feature,
mips_target_feature,
powerpc_target_feature,
s390x_target_feature,
s390x_target_feature_vector,
loongarch_target_feature,
wasm_target_feature,
abi_unadjusted,

View file

@ -12,7 +12,7 @@
//@[z13_no_vector] compile-flags: --target s390x-unknown-linux-gnu -C target-cpu=z13 -C target-feature=-vector --cfg no_vector
//@[z13_no_vector] needs-llvm-components: systemz
#![feature(no_core, lang_items, repr_simd, s390x_target_feature)]
#![feature(no_core, lang_items, repr_simd, s390x_target_feature_vector)]
#![no_core]
#![crate_type = "lib"]
#![allow(non_camel_case_types)]

View file

@ -6,7 +6,7 @@
#![crate_type = "rlib"]
#![feature(no_core, asm_experimental_arch)]
#![feature(s390x_target_feature, simd_ffi, intrinsics, repr_simd)]
#![feature(s390x_target_feature_vector, simd_ffi, intrinsics, repr_simd)]
#![no_core]
extern crate minicore;

View file

@ -5,7 +5,7 @@
repr_simd,
arm_target_feature,
mips_target_feature,
s390x_target_feature,
s390x_target_feature_vector,
riscv_target_feature
)]
#![no_std]

View file

@ -14,7 +14,7 @@
//[z13_no_vector,z13_soft_float]~? WARN unstable feature specified for `-Ctarget-feature`
//[z13_soft_float]~? WARN target feature `soft-float` cannot be enabled with `-Ctarget-feature`
#![feature(no_core, repr_simd, s390x_target_feature)]
#![feature(no_core, repr_simd, s390x_target_feature_vector)]
#![no_core]
#![crate_type = "lib"]
#![allow(non_camel_case_types, improper_ctypes_definitions)]

View file

@ -17,6 +17,7 @@
// gate-test-lahfsahf_target_feature
// gate-test-prfchw_target_feature
// gate-test-s390x_target_feature
// gate-test-s390x_target_feature_vector
// gate-test-sparc_target_feature
// gate-test-x87_target_feature
// gate-test-m68k_target_feature

View file

@ -1,5 +1,5 @@
error[E0658]: the target feature `x87` is currently unstable
--> $DIR/gate.rs:24:18
--> $DIR/gate.rs:25:18
|
LL | #[target_feature(enable = "x87")]
| ^^^^^^^^^^^^^^