From f0b329cad8d31b99dd3a239b45f4d117418d5b86 Mon Sep 17 00:00:00 2001 From: Vladislav Volosnikov Date: Thu, 1 Aug 2024 15:33:03 +0200 Subject: [PATCH] Fix avx512 poseidon2 compilation config --- src/implementations/poseidon2/mod.rs | 8 ++------ src/implementations/poseidon2/state_avx512.rs | 5 ----- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/src/implementations/poseidon2/mod.rs b/src/implementations/poseidon2/mod.rs index 6dbb7e0..c847d95 100644 --- a/src/implementations/poseidon2/mod.rs +++ b/src/implementations/poseidon2/mod.rs @@ -4,11 +4,9 @@ use crate::field::goldilocks::GoldilocksField; pub mod params; pub mod state_generic_impl; -#[cfg(not(all( +#[cfg(not(any( feature = "include_packed_simd", - any( - target_feature = "neon", - target_feature = "avx2", + all( target_feature = "avx512bw", target_feature = "avx512cd", target_feature = "avx512dq", @@ -48,7 +46,6 @@ pub mod state_vectorized_double; pub use state_vectorized_double::*; #[cfg(all( - feature = "include_packed_simd", target_feature = "avx512bw", target_feature = "avx512cd", target_feature = "avx512dq", @@ -58,7 +55,6 @@ pub use state_vectorized_double::*; pub mod state_avx512; #[cfg(all( - feature = "include_packed_simd", target_feature = "avx512bw", target_feature = "avx512cd", target_feature = "avx512dq", diff --git a/src/implementations/poseidon2/state_avx512.rs b/src/implementations/poseidon2/state_avx512.rs index d0a6af5..8cb18b3 100644 --- a/src/implementations/poseidon2/state_avx512.rs +++ b/src/implementations/poseidon2/state_avx512.rs @@ -24,11 +24,6 @@ impl Aligned { } } -// we also need holder for SIMD targets, because u64x4 has smaller alignment than u64x8 -#[derive(Clone, Copy)] -#[repr(C, align(64))] -struct U128x4Holder([packed_simd::u128x4; 3]); - impl std::fmt::Debug for State { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { write!(f, "{:?}", self.0)