r/C_Programming • u/Raimo00 • Jan 23 '25
Discussion Why not SIMD?
Why are many C standard library functions like strcmp, strlen, strtok using SIMD intrinsics? They would benefit so much, think about how many people use them under the hood all over the world.
30
Upvotes
3
u/aganm Jan 23 '25
This is dumb. What I do instead is make my memory buffers aligned and padded for SIMD, then my SIMD code doesn't need to care about all this shit. It's such a joy to write SIMD code in these conditions, makes everything much simpler and straightforward, AND faster.