1 /* { dg-do compile } */
2 /* { dg-options "-mavx512fp16 -mavx512vl -O2" } */
3 /* { dg-final { scan-assembler-times "vcvttph2udq\[ \\t\]+\[^\{\n\]*%xmm\[0-9\]+\[^\n\r]*%ymm\[0-9\]+(?:\n|\[ \\t\]+#)" 1 } } */
4 /* { dg-final { scan-assembler-times "vcvttph2udq\[ \\t\]+%xmm\[0-9\]+\[^\n\r]*%ymm\[0-9\]+\{%k\[0-9\]\}(?:\n|\[ \\t\]+#)" 1 } } */
5 /* { dg-final { scan-assembler-times "vcvttph2udq\[ \\t\]+%xmm\[0-9\]+\[^\n\r]*%ymm\[0-9\]+\{%k\[0-9\]\}\{z\}\[^\n\r]*(?:\n|\[ \\t\]+#)" 1 } } */
6 /* { dg-final { scan-assembler-times "vcvttph2udq\[ \\t\]+%xmm\[0-9\]+\[^\n\r]*%xmm\[0-9\]+(?:\n|\[ \\t\]+#)" 1 } } */
7 /* { dg-final { scan-assembler-times "vcvttph2udq\[ \\t\]+%xmm\[0-9\]+\[^\n\r]*%xmm\[0-9\]+\{%k\[0-9\]\}(?:\n|\[ \\t\]+#)" 1 } } */
8 /* { dg-final { scan-assembler-times "vcvttph2udq\[ \\t\]+%xmm\[0-9\]+\[^\n\r]*%xmm\[0-9\]+\{%k\[0-9\]\}\{z\}\[^\n\r]*(?:\n|\[ \\t\]+#)" 1 } } */
9
10 #include <immintrin.h>
11
12 volatile __m256i res1;
13 volatile __m128i res2;
14 volatile __m128h x3;
15 volatile __mmask8 m8;
16
17 void extern
18 avx512f_test (void)
19 {
20 res1 = _mm256_cvttph_epu32 (x3);
21 res1 = _mm256_mask_cvttph_epu32 (res1, m8, x3);
22 res1 = _mm256_maskz_cvttph_epu32 (m8, x3);
23
24 res2 = _mm_cvttph_epu32 (x3);
25 res2 = _mm_mask_cvttph_epu32 (res2, m8, x3);
26 res2 = _mm_maskz_cvttph_epu32 (m8, x3);
27 }