- HACK Warning: Add from impls for u64x4 <-> f64x4 and f32x8 <-> u32x8
- The 'assert_*' tests for the '*pd' instructions are failing due to llvm always using the single precision ('*ps') variation
_mm_cvtepi32_ps has been implemented, but _mm_cvtps_epi32 is missing.
Use the implementation of _mm_cvtepi32_ps as a guide for implementing
_mm_cvtps_epi32.
* Add vroundps, vceilps, vfloorps, vsqrtps, vsqrtpd
* Uninhibit assert_instr on non-expanded intrinsics
Also use the new simd_test macro
* Use simd_test where possible
* Add automated tests for vround*
* Add target_feature guards to automated tests
* Move automated tests below their functions
This commit switches the remaining "wrapper" tests to assert_instr with
constant parameters. This form of test is necessary when a vendor
intrinsic requires an immediate constant value to optimize properly into
the intended CPU instruction.
Some intrinsics need to be invoked with constant arguments to get the right
instruction to get generated, so this commit enhances the `assert_instr` macro
to enable this ability. Namely you pass constant arguments like:
#[assert_instr(foo, a = b)]
where this will assert that the intrinsic, when invoked with argument `a` equal
to the value `b` and all other arguments passed from the outside, will generate
the instruction `foo`.
Closes#49
This commit alters the test suite to unconditionally compile and run all tests,
regardless of the ambient target features enabled. This then uses a new
convenience macro, `#[simd_test]`, to guard all tests with the appropriate
`cfg_feature_enabled!` and also enable the `#[target_feature]` appropriately.
There's a lot of trickery in this crate which expands to a lot of code, so in
addition to asserting that we find the right instruction, let's assert we find
a small function as well (as these should all be just one or so instructions
anyway).