SIMD: _mm256_cmpgt_epu8_mask

Hi everyone.
I have a little(maybe) question related with SIMD.
I would like just simply compare two 256 bit vector from 8 bit unsigned int. I found a perfect function _mm256_cmpgt_epu8_mask, which compares the two vector and give back a mask.
Unluckily this function (or Assembly) only work on AVX512VL + AVX512BW (only the server CPU).
My question is how can we achieve this comparing?
Is this _mm256_cmpgt_epu8_mask not possible for a normal Intel CPU?
Do we have some alternative solution to solve my problem?

1
2
3
/usr/lib/gcc/x86_64-linux-gnu/7/include/avx512vlbwintrin.h:3224:1: 
error: inlining failed in call to always_inline ‘__mmask32 _mm256_cmpgt_epu8_mask(__m256i, __m256i)’: target specific option mismatch


https://software.intel.com/sites/landingpage/IntrinsicsGuide/#text=_mm256_cmpeq_epu8&expand=811
Last edited on
Try use _mm256_cmpgt_epu8_mask in your progdam. If you get SIGILL signal, use simple memcmp.
(man 7 signal)
You can use __m256i _mm256_cmpgt_epi8 (__m256i a, __m256i b) to do the compare with AVX2 and then if you need to mask the results use an and.
Woops, you asked for unsigned. Sorry the above is for signed.
Topic archived. No new replies allowed.