binius_hash/groestl/arch/
mod.rs

1// Copyright 2024-2025 Irreducible Inc.
2
3use cfg_if::cfg_if;
4
5// We will choose the AVX512 Implementation of Grøstl if our machine supports the various AVX512
6// extensions, otherwise defaults to the portable implementation which was found to be fast in most
7// machines
8cfg_if! {
9	if #[cfg(all(target_arch = "x86_64",target_feature = "avx512bw",target_feature = "avx512vbmi",target_feature = "avx512f",target_feature = "gfni",))] {
10		mod groestl_avx512;
11		pub use groestl_avx512::Groestl256Core;
12	} else {
13		mod groestl_table;
14		mod portable;
15		pub use portable::Groestl256Core;
16	}
17}