diff options
author | Matthias Kretz <m.kretz@gsi.de> | 2023-02-23 14:55:08 +0100 |
---|---|---|
committer | Matthias Kretz <m.kretz@gsi.de> | 2023-03-21 17:47:25 +0100 |
commit | 8ff3ca2d94721fab78f167d435d4ea4fa4fdca6a (patch) | |
tree | d68b0e73a0fc3fe8eb53bab4903cb8f7be5a0f82 /gcc | |
parent | 041a164ec9b467f9ac2f15980f83f17e3f8ea150 (diff) | |
download | gcc-8ff3ca2d94721fab78f167d435d4ea4fa4fdca6a.zip gcc-8ff3ca2d94721fab78f167d435d4ea4fa4fdca6a.tar.gz gcc-8ff3ca2d94721fab78f167d435d4ea4fa4fdca6a.tar.bz2 |
libstdc++: Fix simd compilation with Clang
Clang fails to compile some constant expressions involving simd.
Therefore, just disable this non-conforming extension for clang.
Fix AVX512 blend implementation for Clang. It was converting the bitmask
to bool before, which is obviously wrong. Instead use a Clang builtin to
convert the bitmask to vector-mask before using a vector blend ?:. A
similar change is required for the masked unary implementation, because
the GCC builtins do not exist on Clang.
Signed-off-by: Matthias Kretz <m.kretz@gsi.de>
libstdc++-v3/ChangeLog:
* include/experimental/bits/simd_detail.h: Don't declare the
simd API as constexpr with Clang.
* include/experimental/bits/simd_x86.h (__movm): New.
(_S_blend_avx512): Resolve FIXME. Implement blend using __movm
and ?:.
(_SimdImplX86::_S_masked_unary): Clang does not implement the
same builtins. Implement the function using __movm, ?:, and -
operators on vector_size types instead.
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions