Rollup merge of #139675 - sayantn:avx10, r=Amanieu
Add the AVX10 target features Parent #138843 Adds the `avx10_target_feature` feature gate, and `avx10.1` and `avx10.2` target features. It is confirmed that Intel is dropping AVX10/256 (see [this comment](https://github.com/rust-lang/rust/issues/111137#issuecomment-2795442288)), so this should be safe to implement now. The LLVM fix for llvm/llvm-project#135394 was merged, and has been backported to LLVM20, and the patch has also been propagated to rustc in #140502 `@rustbot` label O-x86_64 O-x86_32 A-target-feature A-SIMD
This commit is contained in:
commit
ed7590f1a0
8 changed files with 48 additions and 1 deletions
|
|
@ -301,6 +301,9 @@ pub(crate) fn to_llvm_features<'a>(sess: &Session, s: &'a str) -> Option<LLVMFea
|
|||
None
|
||||
}
|
||||
("x86", "movrs") if get_version().0 < 20 => None,
|
||||
("x86", "avx10.1") => Some(LLVMFeature::new("avx10.1-512")),
|
||||
("x86", "avx10.2") if get_version().0 < 20 => None,
|
||||
("x86", "avx10.2") if get_version().0 >= 20 => Some(LLVMFeature::new("avx10.2-512")),
|
||||
(_, s) => Some(LLVMFeature::new(s)),
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -393,6 +393,8 @@ declare_features! (
|
|||
(unstable, async_for_loop, "1.77.0", Some(118898)),
|
||||
/// Allows `async` trait bound modifier.
|
||||
(unstable, async_trait_bounds, "1.85.0", Some(62290)),
|
||||
/// Allows using Intel AVX10 target features and intrinsics
|
||||
(unstable, avx10_target_feature, "CURRENT_RUSTC_VERSION", Some(138843)),
|
||||
/// Allows using C-variadics.
|
||||
(unstable, c_variadic, "1.34.0", Some(44930)),
|
||||
/// Allows the use of `#[cfg(contract_checks)` to check if contract checks are enabled.
|
||||
|
|
|
|||
|
|
@ -531,6 +531,7 @@ symbols! {
|
|||
autodiff,
|
||||
automatically_derived,
|
||||
avx,
|
||||
avx10_target_feature,
|
||||
avx512_target_feature,
|
||||
avx512bw,
|
||||
avx512f,
|
||||
|
|
|
|||
|
|
@ -394,6 +394,26 @@ static X86_FEATURES: &[(&str, Stability, ImpliedFeatures)] = &[
|
|||
("amx-tile", Unstable(sym::x86_amx_intrinsics), &[]),
|
||||
("amx-transpose", Unstable(sym::x86_amx_intrinsics), &["amx-tile"]),
|
||||
("avx", Stable, &["sse4.2"]),
|
||||
(
|
||||
"avx10.1",
|
||||
Unstable(sym::avx10_target_feature),
|
||||
&[
|
||||
"avx512bf16",
|
||||
"avx512bitalg",
|
||||
"avx512bw",
|
||||
"avx512cd",
|
||||
"avx512dq",
|
||||
"avx512f",
|
||||
"avx512fp16",
|
||||
"avx512ifma",
|
||||
"avx512vbmi",
|
||||
"avx512vbmi2",
|
||||
"avx512vl",
|
||||
"avx512vnni",
|
||||
"avx512vpopcntdq",
|
||||
],
|
||||
),
|
||||
("avx10.2", Unstable(sym::avx10_target_feature), &["avx10.1"]),
|
||||
("avx2", Stable, &["avx"]),
|
||||
("avx512bf16", Unstable(sym::avx512_target_feature), &["avx512bw"]),
|
||||
("avx512bitalg", Unstable(sym::avx512_target_feature), &["avx512bw"]),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue