Skip to content

0.2.0

Latest

Choose a tag to compare

@jlogan03 jlogan03 released this 05 Aug 00:58
bd09e4f

Changes

Improve error handling, parametrize storage, and add operations (#8)

  • Replace assert! and panic! error handling with propagation of Result
    • <10% throughput hit at any benchmarked condition, and improvements for some
    • Make inner functions for operations (potentially) fallible
      • Supports explicitly checking slice lengths to eliminate panic branches
      • Supports user-defined operations that are fallible
  • Make intermediate storage customizable to better support both application-level and embedded usages
    • Add const generic parametrization of the size of storage
    • Add compile-time customizable alignment for storage
  • Add new logical operations
    • min, max (for strictly Ord types, not float), fmin, fmax (floating-point NaN-handling min and max), lt, le, gt, ge, eq, ne
    • Logical operations return T::one() or T::zero() instead of boolean
  • Update benchmarks to allocate separate arrays for all inputs
    • This helps to more-fairly test the Vec based methods, which otherwise derive a distinct and unrealistic advantage from only operating on a single input array for a many-step expression
    • This has a much smaller effect on strobe, as its main feature is to reduce dependence on the locality of the input data
    • Benchmarks now show strobe out-performing simple vectorization recipes for realistic expressions of depth 2 and higher (was 3 and higher)