lib.rsannotatedlib.rssource19 lines · 558 B · raw
1pub mod design;
2pub mod iir;
3pub mod sinc;
4
5#[cfg(target_arch = "x86_64")]
6macro_rules! option_env_is_none_or_empty {
7    ($var:literal) => {
8        match option_env!($var) {
9            Some(var) => var.is_empty(),
10            None => true,
11        }
12    };
13}

Compile-time env vars to disable AVX2 and AVX512 code paths for testing

16#[cfg(target_arch = "x86_64")]
17const AVX2_ENABLED: bool = option_env_is_none_or_empty!("JGENESIS_NO_AVX2");
18#[cfg(target_arch = "x86_64")]
19const AVX512_ENABLED: bool = option_env_is_none_or_empty!("JGENESIS_NO_AVX512");