diff --git a/Cargo.toml b/Cargo.toml index 40ea48204eb..9284f3084fd 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -61,8 +61,8 @@ serde = { version = "1.0.103", features = ["derive"], optional = true } [dependencies.packed_simd] # NOTE: so far no version works reliably due to dependence on unstable features -version = "0.3" -# git = "https://github.com/rust-lang-nursery/packed_simd" +package = "packed_simd_2" +version = "0.3.4" optional = true features = ["into_bits"] diff --git a/src/distributions/integer.rs b/src/distributions/integer.rs index 13ed113b00d..8a2ce4cf1e6 100644 --- a/src/distributions/integer.rs +++ b/src/distributions/integer.rs @@ -11,9 +11,9 @@ use crate::distributions::{Distribution, Standard}; use crate::Rng; #[cfg(all(target_arch = "x86", feature = "simd_support"))] -use core::arch::x86::{__m64, __m128i, __m256i}; +use core::arch::x86::{__m128i, __m256i}; #[cfg(all(target_arch = "x86_64", feature = "simd_support"))] -use core::arch::x86_64::{__m64, __m128i, __m256i}; +use core::arch::x86_64::{__m128i, __m256i}; #[cfg(not(target_os = "emscripten"))] use core::num::NonZeroU128; use core::num::{NonZeroU16, NonZeroU32, NonZeroU64, NonZeroU8, NonZeroUsize}; #[cfg(feature = "simd_support")] use packed_simd::*; @@ -158,7 +158,7 @@ simd_impl!(512, u8x64, i8x64, u16x32, i16x32, u32x16, i32x16, u64x8, i64x8,); feature = "simd_support", any(target_arch = "x86", target_arch = "x86_64") ))] -simd_impl!((__m64, u8x8), (__m128i, u8x16), (__m256i, u8x32),); +simd_impl!((__m128i, u8x16), (__m256i, u8x32),); #[cfg(test)] mod tests { diff --git a/src/distributions/utils.rs b/src/distributions/utils.rs index f965bbcb4fd..e3bceb8a96c 100644 --- a/src/distributions/utils.rs +++ b/src/distributions/utils.rs @@ -159,9 +159,8 @@ mod simd_wmul { } wmul_impl! { (u16x2, u32x2),, 16 } - #[cfg(not(target_feature = "sse2"))] wmul_impl! { (u16x4, u32x4),, 16 } - #[cfg(not(target_feature = "sse4.2"))] + #[cfg(not(target_feature = "sse2"))] wmul_impl! { (u16x8, u32x8),, 16 } #[cfg(not(target_feature = "avx2"))] wmul_impl! { (u16x16, u32x16),, 16 } @@ -187,8 +186,6 @@ mod simd_wmul { } #[cfg(target_feature = "sse2")] - wmul_impl_16! { u16x4, __m64, _mm_mulhi_pu16, _mm_mullo_pi16 } - #[cfg(target_feature = "sse4.2")] wmul_impl_16! { u16x8, __m128i, _mm_mulhi_epu16, _mm_mullo_epi16 } #[cfg(target_feature = "avx2")] wmul_impl_16! { u16x16, __m256i, _mm256_mulhi_epu16, _mm256_mullo_epi16 }