4 ms·
Yes, but then you have to write (and debug and maintain) each part 3 times. There are also various libraries that create cross platform abstractions of the und
by dagw 2y ago
Yes, but then you have to write (and debug and maintain) each part 3 times.
There are also various libraries that create cross platform abstractions of the underlying SIMD libraries. Highway, from Google, and xSIMD are two popular such libraries for C++. SIMDe is a nice library that also works with C.
- pmarreck 2y ago> Yes, but then you have to write (and debug and maintain) each part 3 times. could you not use a test suite structure (not saying it would be simple) that would run the suite across 3 different virtualized chip implementations? (The virtualization itself might introduce issues, of course)
- datadeft 2y ago> each part 3 times. True. So most projects just use SIMDe, xSIMD or something similar for such use cases?
- astrange 2y agoFFmpeg is the most successful of such projects and it uses handwritten assembly. Ignore the seductive whispers of people trying to sell you unreliable abstractions. It's like this for good reasons.
- dagw 2y agoOr you just say that my code is only fast on hardware that supports nativ AVX512 (or whatever). In many cases where speed really matters that is a reasonable tradeoff to make.