Macro simdeez::simd_runtime_generate
source · macro_rules! simd_runtime_generate {
($vis:vis fn $fn_name:ident ($($arg:ident:$typ:ty),* $(,)? ) $(-> $rt:ty)? $body:block ) => { ... };
}
Expand description
Generates a generic version of your function (fn_name), and versions for:
- AVX2 (fn_name_avx2)
- AVX (fn_name_avx)
- SSE41 (fn_name_sse41)
- SSE2 (fn_name_sse2)
- Scalar fallback (fn_name_scalar) Finally, it also generates a function which will select at runtime the fastest version from above that the cpu supports. (fn_name_runtime_select)