PR target/80969 - Fix ICE with -mabi=ms -mavx512f, reduce wasted space when realignin...
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / avx512bw-vpsubb-1.c
blob097443f7e1a90dbdc592f9cfd093e25bafd600c2
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -mavx512bw -mavx512vl" } */
3 /* { dg-final { scan-assembler-times "vpsubb\[ \\t\]+\[^\{\n\]*%zmm\[0-9\]+(?:\n|\[ \\t\]+#)" 1 } } */
4 /* { dg-final { scan-assembler-times "vpsubb\[ \\t\]+\[^\{\n\]*%zmm\[0-9\]+\{%k\[1-7\]\}(?:\n|\[ \\t\]+#)" 1 } } */
5 /* { dg-final { scan-assembler-times "vpsubb\[ \\t\]+\[^\{\n\]*%zmm\[0-9\]+\{%k\[1-7\]\}\{z\}(?:\n|\[ \\t\]+#)" 1 } } */
6 /* { dg-final { scan-assembler-times "vpsubb\[ \\t\]+\[^\{\n\]*%ymm\[0-9\]+\{%k\[1-7\]\}(?:\n|\[ \\t\]+#)" 1 } } */
7 /* { dg-final { scan-assembler-times "vpsubb\[ \\t\]+\[^\{\n\]*%ymm\[0-9\]+\{%k\[1-7\]\}\{z\}(?:\n|\[ \\t\]+#)" 1 } } */
8 /* { dg-final { scan-assembler-times "vpsubb\[ \\t\]+\[^\{\n\]*%xmm\[0-9\]+\{%k\[1-7\]\}(?:\n|\[ \\t\]+#)" 1 } } */
9 /* { dg-final { scan-assembler-times "vpsubb\[ \\t\]+\[^\{\n\]*%xmm\[0-9\]+\{%k\[1-7\]\}\{z\}(?:\n|\[ \\t\]+#)" 1 } } */
11 #include <immintrin.h>
13 volatile __m512i x512;
14 volatile __m256i x256;
15 volatile __m128i x128;
16 volatile __mmask64 m512;
17 volatile __mmask32 m256;
18 volatile __mmask16 m128;
20 void extern
21 avx512bw_test (void)
23 x512 = _mm512_sub_epi8 (x512, x512);
24 x512 = _mm512_mask_sub_epi8 (x512, m512, x512, x512);
25 x512 = _mm512_maskz_sub_epi8 (m512, x512, x512);
26 x256 = _mm256_mask_sub_epi8 (x256, m256, x256, x256);
27 x256 = _mm256_maskz_sub_epi8 (m256, x256, x256);
28 x128 = _mm_mask_sub_epi8 (x128, m128, x128, x128);
29 x128 = _mm_maskz_sub_epi8 (m128, x128, x128);