Last active
September 12, 2020 00:25
-
-
Save malfet/ccb6de5b16101c698e17f52bdf1a1f73 to your computer and use it in GitHub Desktop.
GCC masm=intel bug
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // gcc -c -Os -mavx512f -masm=intel | |
| #include <immintrin.h> | |
| float foo(float* con) { | |
| __mmask16 msk = 0x00ff; | |
| __m512 a = _mm512_maskz_loadu_ps(msk, con); | |
| __m512 b = _mm512_set1_ps(con[1]); | |
| __m512 c = _mm512_mul_ps(a,b); | |
| return ((float *)&c)[0]; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment