Skip to main content

SimdConfig

Trait SimdConfig 

Source
pub trait SimdConfig {
    // Required methods
    fn set_simd_width(&mut self, width: usize);
    fn simd_width(&self) -> usize;
    fn set_scalar_fallback(&mut self, enabled: bool);
    fn scalar_fallback_enabled(&self) -> bool;
    fn set_precision_tolerance(&mut self, tolerance: f64);
    fn precision_tolerance(&self) -> f64;
}
Expand description

Configuration trait for SIMD operations

Required Methods§

Source

fn set_simd_width(&mut self, width: usize)

Set the preferred SIMD width

Source

fn simd_width(&self) -> usize

Get the current SIMD width

Source

fn set_scalar_fallback(&mut self, enabled: bool)

Enable/disable automatic fallback to scalar

Source

fn scalar_fallback_enabled(&self) -> bool

Check if scalar fallback is enabled

Source

fn set_precision_tolerance(&mut self, tolerance: f64)

Set numerical precision requirements

Source

fn precision_tolerance(&self) -> f64

Get current precision tolerance

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§