Skip to main content

Module optimized_binary

Module optimized_binary 

Source
Expand description

Optimized CPU binary operations for maximum performance

This module provides highly optimized CPU implementations of binary operations that aim to match NumPy’s performance through:

  • SIMD-friendly memory access patterns
  • Vectorized operations using rayon
  • Zero-copy optimizations where possible
  • Specialized fast paths for common cases

Structs§

OptimizedAddOp
Optimized addition operation
OptimizedDivOp
Optimized division operation
OptimizedMulOp
Optimized multiplication operation
OptimizedSubOp
Optimized subtraction operation

Traits§

OptimizedBinaryOp
Optimized binary operation trait with vectorized implementations

Functions§

optimized_add
optimized_binary_op
Optimized binary operation with fast paths for common cases
optimized_binary_op_copy
Optimized binary operation with fast paths for Copy types (avoids cloning)
optimized_div
optimized_mul
optimized_sub