Skip to content

Commit 360a285

Browse files
committed
Add automatic-verification for the F16C intrinsics
1 parent 3dec358 commit 360a285

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

crates/stdsimd-verify/tests/x86-intel.rs

+8-3
Original file line numberDiff line numberDiff line change
@@ -293,11 +293,16 @@ fn matches(rust: &Function, intel: &Intrinsic) -> Result<(), String> {
293293
.flat_map(|c| c.to_lowercase())
294294
.collect::<String>();
295295

296-
// The XML file names IFMA as "avx512ifma52", while Rust calls
297-
// it "avx512ifma". Fix this mismatch by replacing the Intel
298-
// name with the Rust name.
296+
// Fix mismatching feature names:
299297
let fixup_cpuid = |cpuid: String| match cpuid.as_ref() {
298+
// The XML file names IFMA as "avx512ifma52", while Rust calls
299+
// it "avx512ifma".
300300
"avx512ifma52" => String::from("avx512ifma"),
301+
// See: https://github.com/rust-lang-nursery/stdsimd/issues/738
302+
// FIXME: we need to fix "fp16c" to "f16c" here. Since
303+
// https://github.com/rust-lang/rust/pull/60191 is not merged,
304+
// we temporarily map it to "avx512f".
305+
"fp16c" => String::from("avx512f"),
301306
_ => cpuid,
302307
};
303308
let fixed_cpuid = fixup_cpuid(cpuid);

0 commit comments

Comments
 (0)