Closed Proudsalsa closed 7 months ago
Thank you @Proudsalsa ; can you add additional test cases so we don't make these mistakes again?
i added the testcases by adding an additional element to the test vectors. I hope this is fine.
I ran the tests as described in the CONTRIBUTING.md and checked if they detect an error when run with the old implementation as well.
Hi,
There is an error in the implementation of simde_mm256_sign_epi16(). The implementation does not handle the "==0" case of the avx2 intrinsic. I didn't understand the entire test workflow but i would guess that the error is not detected because the test vector in test_simde_mm256_sign_epi16() doesn't contain any 0s.
Feel free to edit the pull request/code.
This is the Pseudo code of the _mm256_sign_epi16 intrinsic from the Intel Intrinsics guide: