summaryrefslogtreecommitdiffstats
path: root/config.tests
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2018-09-13 22:57:30 -0700
committerThiago Macieira <thiago.macieira@intel.com>2018-09-15 20:55:25 +0000
commitd241616e412c9f33fbc4bffce8811aaab79313dd (patch)
tree0ef938123a75bc844e6f2447e2be1eae0061d10a /config.tests
parent6bb0cbc6865911c31f5edee7c24f270d265bd46d (diff)
AVX512 test: an intrinsic that GCC forgot to implement prior to GCC8
_mm512_mask_cvtepi32_storeu_epi8 is VPMOVDB (convert from 32-bit to 8-bit with truncation) where the destination is a memory address, with an OpMask register used to indicate which of the lanes in the vector to store. Similarly, _mm512_mask_cvtepi16_storeu_epi8 is VPMOVWB (convert from 16-bit o 8-bit), which is useful for UTF-16 to Latin1 conversion. Change-Id: I8f261579aad648fdb4f0fffd15542ea306841ce6 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'config.tests')
-rw-r--r--config.tests/avx512/avx512.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/config.tests/avx512/avx512.cpp b/config.tests/avx512/avx512.cpp
index 29e88ebf15..4d47db8463 100644
--- a/config.tests/avx512/avx512.cpp
+++ b/config.tests/avx512/avx512.cpp
@@ -65,6 +65,10 @@ int main(int, char**argv)
d = _mm512_loadu_pd((double *)argv + 64);
f = _mm512_loadu_ps((float *)argv + 128);
+ // some intrinsic that GCC forgot until GCC 8
+ i = _mm512_maskz_set1_epi32(m, '?');
+ _mm512_mask_cvtepi32_storeu_epi8(argv, m, i);
+
#ifdef WANT_AVX512ER
/* AVX512 Exponential and Reciprocal */
f = _mm512_exp2a23_round_ps(f, 8);
@@ -84,6 +88,7 @@ int main(int, char**argv)
#ifdef WANT_AVX512BW
/* AVX512 Byte and Word support */
i = _mm512_mask_loadu_epi8(i, m, argv - 8);
+ _mm512_mask_cvtepi16_storeu_epi8(argv + 8, m, i);
#endif
#ifdef WANT_AVX512VL
/* AVX512 Vector Length */