[committed] libstdc++: Protect against macros
Checks
Commit Message
pushed to trunk, will backport later
tested on x86_64-pc-linux-gnu
------- >8 --------
Signed-off-by: Matthias Kretz <m.kretz@gsi.de>
libstdc++-v3/ChangeLog:
* include/experimental/bits/simd.h (__bit_cast): Use
__gnu__::__vector_size__ instead of gnu::vector_size.
---
libstdc++-v3/include/experimental/bits/simd.h | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
--
──────────────────────────────────────────────────────────────────────────
Dr. Matthias Kretz https://mattkretz.github.io
GSI Helmholtz Centre for Heavy Ion Research https://gsi.de
stdₓ::simd
──────────────────────────────────────────────────────────────────────────
@@ -1743,18 +1743,18 @@ __bit_cast(const _From __x)
return reinterpret_cast<_To>(__x);
else if constexpr (__is_vector_type_v<_To> && __from_is_vectorizable)
{
- using _FV [[gnu::vector_size(sizeof(_From))]] = _From;
+ using _FV [[__gnu__::__vector_size__(sizeof(_From))]] = _From;
return reinterpret_cast<_To>(_FV{__x});
}
else if constexpr (__to_is_vectorizable && __from_is_vectorizable)
{
- using _TV [[gnu::vector_size(sizeof(_To))]] = _To;
- using _FV [[gnu::vector_size(sizeof(_From))]] = _From;
+ using _TV [[__gnu__::__vector_size__(sizeof(_To))]] = _To;
+ using _FV [[__gnu__::__vector_size__(sizeof(_From))]] = _From;
return reinterpret_cast<_TV>(_FV{__x})[0];
}
else if constexpr (__to_is_vectorizable && __is_vector_type_v<_From>)
{
- using _TV [[gnu::vector_size(sizeof(_To))]] = _To;
+ using _TV [[__gnu__::__vector_size__(sizeof(_To))]] = _To;
return reinterpret_cast<_TV>(__x)[0];
}
else