-
Notifications
You must be signed in to change notification settings - Fork 290
Adding the x86 part of behavioural testing for std::arch intrinsics #1814
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
base: master
Are you sure you want to change the base?
Adding the x86 part of behavioural testing for std::arch intrinsics #1814
Conversation
trait to make the same dyn-compatible.
intrinsic-test's X86IntrinsicType struct
b2777ac
to
7047369
Compare
match self { | ||
Self::BFloat => "bfloat", | ||
Self::Float => "float", | ||
Self::Int => "int", | ||
Self::UInt => "uint", | ||
Self::Double => "double", | ||
Self::Int(true) => "int", | ||
Self::Int(false) => "uint", | ||
Self::Poly => "poly", | ||
Self::Void => "void", | ||
Self::Char(true) => "char", | ||
Self::Char(false) => "unsigned char", | ||
Self::Short(true) => "short", | ||
Self::Short(false) => "unsigned short", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Amanieu @adamgemmell Are we using this trait (fmt::Display for TypeKind
) anywhere in the crate? I was searching for its usage and I was unable to find any.
If we are not using this trait, may I delete the definition?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suspect this may be useful for debug output during development. However since it isn't used for functionality then it's fine to make any changes you want to it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it.
Pardon the git history, I will be sorting that out shortly |
b943e51
to
d46a708
Compare
It modernizes the coding style of the crate intrinsic-test by fixing Clippy warnings. Clippy: rust version 1.89.0-nightly (6f6971078 2025-05-28) Number of Fixed Warnings: 36/36
IntrinsicType impl
1. filtered any intrinsic arguments where the only parameter is of type "void" 2. Better parsing for intrinsic return type 3. Filtering intrinsics that are difficult to test (void returns) 4. Reduced the variants in TypeKind (which differed only in bit_len)
necessary. Further notes: 1. IntrinsicType.target -> IntrinsicType.metadata 2. Maintaining a HashMap to support arbitrary data storage for other arch
To make the type names to test correct, this commit replaces occurrences of `rust_prefix` to `c_prefix` where necessary.
It seems it returns true when *no* constraints are found, opposite to the expected behavior of the function name. This commit reverses condition as the name suggests.
ca3e872
to
ed8dfde
Compare
ed8dfde
to
e6ff768
Compare
No description provided.