rust-hdf5 0.7.2

Pure Rust HDF5 library with full read/write and SWMR support
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
//! The run-time SIMD level the crate's kernels dispatch on.
//!
//! `fearless_simd` picks AVX2, AVX-512 or NEON at run time; the loops the
//! compiler vectorizes on its own only reach the baseline the binary was
//! compiled for (SSE2 on x86_64). The level is detected once per process.

use fearless_simd::Level;
use std::sync::OnceLock;

/// The detected level, once per process.
pub(crate) fn level() -> Level {
    static LEVEL: OnceLock<Level> = OnceLock::new();
    *LEVEL.get_or_init(Level::new)
}