pub struct SimdCapabilities {
pub sse4_2: bool,
pub avx2: bool,
pub avx512: bool,
pub neon: bool,
}
Expand description
SIMD instruction set capabilities
Fields§
§sse4_2: bool
SSE 4.2 support
avx2: bool
AVX2 support
avx512: bool
AVX-512 support
neon: bool
ARM NEON support
Implementations§
Source§impl SimdCapabilities
impl SimdCapabilities
Sourcepub fn from_flags(flags: &[String]) -> Self
pub fn from_flags(flags: &[String]) -> Self
Detect SIMD capabilities from CPU flags
Sourcepub fn best_available(&self) -> SimdInstructionSet
pub fn best_available(&self) -> SimdInstructionSet
Get the best available SIMD instruction set
Trait Implementations§
Source§impl Clone for SimdCapabilities
impl Clone for SimdCapabilities
Source§fn clone(&self) -> SimdCapabilities
fn clone(&self) -> SimdCapabilities
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for SimdCapabilities
impl Debug for SimdCapabilities
Source§impl Default for SimdCapabilities
impl Default for SimdCapabilities
Source§fn default() -> SimdCapabilities
fn default() -> SimdCapabilities
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for SimdCapabilities
impl RefUnwindSafe for SimdCapabilities
impl Send for SimdCapabilities
impl Sync for SimdCapabilities
impl Unpin for SimdCapabilities
impl UnwindSafe for SimdCapabilities
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more