Skip to content

SIMD Algorithms v1.1.0

Latest
Compare
Choose a tag to compare
@MrUnbelievable92 MrUnbelievable92 released this 09 Aug 05:04

Additions

  • Added "SIMD_MinMax" functions to all types and contiguous Unity.Collections containers
  • Added a "Comparison" enum that is used in "IndexOf", "Contains" and "Count" algorithms, giving the caller a choice to express primitive where clauses, like "index of first x where x > 9000"

Improvements

  • Substantially improved performance and reduced code size of "SIMD_Count" functions for all types (and added caller-site optimization options - see below)
  • "SIMD_Count" functions now have a TypeCode parameter "returnType" (set to the most inefficient - "TypeCode.UInt64" - by default) (unless the underlying type is exactly 64 bits wide), which can be overwritten for (s)byte and (u)short containers, in order to enable optimizations
  • Slightly improved performance of "SIMD_Contains" functions for all types
  • Improved performance of "SIMD_Min" and "SIMD_Max" functions for very small arrays for all types

Changes

  • API BREAKING CHANGE: "SIMD_Count" extension methods now return ints (...since native collections "only" hold up to int.MaxValue elements)
  • API BREAKING CHANGE: Any call-sites which explicitly declared an array traversal order before ("SIMD_Contains" and/or "SIMD_IndexOf") now require either an explicit "Comparison.EqualTo" parameter or a "traversalOrder:" named parameter declaration