Daily bump.
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / avx512vl-vpexpandw-1.c
blobac5c34a0f425de04cb55bc1fedde42ff35474492
1 /* { dg-do compile } */
2 /* { dg-options "-mavx512vbmi2 -mavx512bw -mavx512vl -O2" } */
3 /* { dg-final { scan-assembler-times "vpexpandw\[ \\t\]+\[^\{\n\]*%ymm\[0-9\]+\[^\n\]*%ymm\[0-9\]+\{%k\[1-7\]\}(?:\n|\[ \\t\]+#)" 1 } } */
4 /* { dg-final { scan-assembler-times "vpexpandw\[ \\t\]+\[^\{\n\]*%xmm\[0-9\]+\[^\n\]*%xmm\[0-9\]+\{%k\[1-7\]\}(?:\n|\[ \\t\]+#)" 1 } } */
5 /* { dg-final { scan-assembler-times "vpexpandw\[ \\t\]+\[^\{\n\]*%ymm\[0-9\]+\[^\n\]*%ymm\[0-9\]+\{%k\[1-7\]\}\{z\}(?:\n|\[ \\t\]+#)" 1 } } */
6 /* { dg-final { scan-assembler-times "vpexpandw\[ \\t\]+\[^\{\n\]*%xmm\[0-9\]+\[^\n\]*%xmm\[0-9\]+\{%k\[1-7\]\}\{z\}(?:\n|\[ \\t\]+#)" 1 } } */
7 /* { dg-final { scan-assembler-times "vpexpandw\[ \\t\]+\[^\{\n\]*\\(\[^\n\]*%ymm\[0-9\]+\{%k\[1-7\]\}(?:\n|\[ \\t\]+#)" 1 } } */
8 /* { dg-final { scan-assembler-times "vpexpandw\[ \\t\]+\[^\{\n\]*\\(\[^\n\]*%xmm\[0-9\]+\{%k\[1-7\]\}(?:\n|\[ \\t\]+#)" 1 } } */
9 /* { dg-final { scan-assembler-times "vpexpandw\[ \\t\]+\[^\{\n\]*\\(\[^\n\]*%ymm\[0-9\]+\{%k\[1-7\]\}\{z\}(?:\n|\[ \\t\]+#)" 1 } } */
10 /* { dg-final { scan-assembler-times "vpexpandw\[ \\t\]+\[^\{\n\]*\\(\[^\n\]*%xmm\[0-9\]+\{%k\[1-7\]\}\{z\}(?:\n|\[ \\t\]+#)" 1 } } */
12 #include <immintrin.h>
14 int *p;
15 volatile __m256i x1;
16 volatile __m128i x2;
17 volatile __mmask8 m;
19 void extern
20 avx512vl_test (void)
22 x1 = _mm256_mask_expand_epi16 (x1, m, x1);
23 x2 = _mm_mask_expand_epi16 (x2, m, x2);
25 x1 = _mm256_maskz_expand_epi16 (m, x1);
26 x2 = _mm_maskz_expand_epi16 (m, x2);
28 x1 = _mm256_mask_expandloadu_epi16 (x1, m, p);
29 x2 = _mm_mask_expandloadu_epi16 (x2, m, p);
31 x1 = _mm256_maskz_expandloadu_epi16 (m, p);
32 x2 = _mm_maskz_expandloadu_epi16 (m, p);