Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exclude intel SVML functions from missing intrinsics report #1253

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
23 changes: 10 additions & 13 deletions crates/stdarch-verify/tests/x86-intel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ struct Intrinsic {
#[serde(rename = "return")]
return_: Return,
name: String,
tech: String,
#[serde(rename = "CPUID", default)]
cpuid: Vec<String>,
#[serde(rename = "parameter", default)]
Expand Down Expand Up @@ -155,7 +156,7 @@ fn verify_all_signatures() {
// https://software.intel.com/sites/landingpage/IntrinsicsGuide/#
//
// Open up the network console and you'll see an xml file was downloaded
// (currently called data-3.4.xml). That's the file we downloaded
// (currently called data-3.6.xml). That's the file we downloaded
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ignoring pack files this update will grow the repo size by 6.74 MB. With pack files, it will likely be a bit smaller, though possibly not by much.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point, I did not consider the size. If that is a concern I could revert and rebase adding this file. It could be added once there are actual plans to implement to implement for example the VNNI or FP16 extensions. My goal is to work on avx512f and avx512vl for now, especially masked loads/stores.

// here.
let xml = include_bytes!("../x86-intel.xml");

Expand Down Expand Up @@ -381,17 +382,14 @@ fn verify_all_signatures() {
continue;
}

// we'll get to avx-512 later
// let avx512 = intel.iter().any(|i| {
// i.name.starts_with("_mm512") || i.cpuid.iter().any(|c| {
// c.contains("512")
// })
// });
// if avx512 {
// continue
// }

for intel in intel {
// ignore intrinsics from Intel's Short Vector Math Library (SVML)
// these don't map directly to single instructions but correspond
// to optimized functions implemented in that library
if intel.tech == "SVML" {
continue;
}

missing
.entry(&intel.cpuid)
.or_insert_with(Vec::new)
Expand All @@ -406,8 +404,7 @@ fn verify_all_signatures() {
println!("\n<details><summary>{:?}</summary><p>\n", k);
for intel in v {
let url = format!(
"https://software.intel.com/sites/landingpage\
/IntrinsicsGuide/#text={}&expand=5236",
"https://software.intel.com/sites/landingpage/IntrinsicsGuide/#text={}",
intel.name
);
println!(" * [ ] [`{}`]({})", intel.name, url);
Expand Down