I need to compute an element-wise max and I see that there are Intel intrinsics for that:
__m128i _mm_max_epi8 (__m128i a, __m128i b)
__m256i _mm256_max_epi8 (__m256i a, __m256i b)
Compare packed signed 8-bit integers in a and b, and store packed maximum values in dst.
and similar.
I wonder if xsimd already has an API for element-wise max / min. I looked in the documentation, but didn't find it. Would it make sense to add?
As a workaround, I'm currently using le + select.
auto lt = xsimd::lt(batch, otherBatch);
auto maxBatch = xsimd::select(lt, otherBatch, batch);
I need to compute an element-wise max and I see that there are Intel intrinsics for that:
and similar.
I wonder if xsimd already has an API for element-wise max / min. I looked in the documentation, but didn't find it. Would it make sense to add?
As a workaround, I'm currently using le + select.
CC: @kgpai @Yuhta