r/programming • u/awesomePop7291 • Jul 23 '26
Everyone Should Know SIMD
https://mitchellh.com/writing/everyone-should-know-simd
412
Upvotes
r/programming • u/awesomePop7291 • Jul 23 '26
View all comments
Show parent comment
1
u/barsoap Jul 24 '26
I'm reasonably sure both of those are compiler intrinsics.
In general you're right, that's a zig limitation that doesn't exist with actual vector instructions. I guess the reason for comptime-known length is avoiding management overhead on SIMD for vectors that are known to be even sizes. Which happens quite a lot.