SIMD: Am I holding it wrong?

oh my, this brings back a memory of a time i worked on a spherical geo project that we decided to write in Float thinking it would be easier to interface with the GPU-side of the project that only spoke Float. then halfway through we discovered Float was nowhere near precise enough for spherical algorithms so we had to migrate the whole thing to Double. which wasn’t that bad since it only involved a bunch of find-and-replaces (FloatVector –> DoubleVector, etc) and rewrapping some overflowing lines. but my point is it's hard to anticipate ahead of time what floating point specialization you need unless you've already got a ton of experience with numerics. anyway, just a random anecdote.

yeah, this is definitely still a major pain point with swift generics.

5 Likes