pub struct BasicOps;Expand description
Basic SIMD-optimized element-wise operations
Implementations§
Source§impl BasicOps
impl BasicOps
Sourcepub fn add_f32_unchecked(a: &[f32], b: &[f32], result: &mut [f32])
pub fn add_f32_unchecked(a: &[f32], b: &[f32], result: &mut [f32])
Fast inline element-wise addition without bounds checking (for hot paths)
Sourcepub fn add_f32_optimized(a: &[f32], b: &[f32], result: &mut [f32]) -> Result<()>
pub fn add_f32_optimized(a: &[f32], b: &[f32], result: &mut [f32]) -> Result<()>
Element-wise addition with SciRS2-Core SIMD auto-vectorization (safe version)
Sourcepub fn mul_f32_unchecked(a: &[f32], b: &[f32], result: &mut [f32])
pub fn mul_f32_unchecked(a: &[f32], b: &[f32], result: &mut [f32])
Fast inline element-wise multiplication without bounds checking (for hot paths)
Sourcepub fn mul_f32_optimized(a: &[f32], b: &[f32], result: &mut [f32]) -> Result<()>
pub fn mul_f32_optimized(a: &[f32], b: &[f32], result: &mut [f32]) -> Result<()>
Element-wise multiplication with optimization hints for f32 tensors (safe version)
Sourcepub fn sub_f32_unchecked(a: &[f32], b: &[f32], result: &mut [f32])
pub fn sub_f32_unchecked(a: &[f32], b: &[f32], result: &mut [f32])
Fast inline element-wise subtraction without bounds checking (for hot paths)
Sourcepub fn sub_f32_optimized(a: &[f32], b: &[f32], result: &mut [f32]) -> Result<()>
pub fn sub_f32_optimized(a: &[f32], b: &[f32], result: &mut [f32]) -> Result<()>
Element-wise subtraction with optimization hints for f32 tensors (safe version)
Sourcepub fn fma_f32_unchecked(a: &[f32], b: &[f32], c: &[f32], result: &mut [f32])
pub fn fma_f32_unchecked(a: &[f32], b: &[f32], c: &[f32], result: &mut [f32])
Ultra-high-performance fused multiply-add operation (a * b + c)
Auto Trait Implementations§
impl Freeze for BasicOps
impl RefUnwindSafe for BasicOps
impl Send for BasicOps
impl Sync for BasicOps
impl Unpin for BasicOps
impl UnsafeUnpin for BasicOps
impl UnwindSafe for BasicOps
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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