mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-08-12 11:49:02 +08:00
bug #1718: Add cast to successfully compile with clang on PowerPC
Ignoring -Wc11-extensions warnings thrown by clang at Altivec/PacketMath.h
This commit is contained in:
parent
d55d392e7b
commit
66d073c38e
@ -452,7 +452,7 @@ template<> EIGEN_STRONG_INLINE Packet4f pandnot<Packet4f>(const Packet4f& a, con
|
|||||||
template<> EIGEN_STRONG_INLINE Packet4i pandnot<Packet4i>(const Packet4i& a, const Packet4i& b) { return vec_and(a, vec_nor(b, b)); }
|
template<> EIGEN_STRONG_INLINE Packet4i pandnot<Packet4i>(const Packet4i& a, const Packet4i& b) { return vec_and(a, vec_nor(b, b)); }
|
||||||
|
|
||||||
template<> EIGEN_STRONG_INLINE Packet4f pselect(const Packet4f& mask, const Packet4f& a, const Packet4f& b) {
|
template<> EIGEN_STRONG_INLINE Packet4f pselect(const Packet4f& mask, const Packet4f& a, const Packet4f& b) {
|
||||||
return vec_sel(b, a, mask);
|
return vec_sel(b, a, reinterpret_cast<Packet4ui>(mask));
|
||||||
}
|
}
|
||||||
|
|
||||||
template<> EIGEN_STRONG_INLINE Packet4f pround<Packet4f>(const Packet4f& a) { return vec_round(a); }
|
template<> EIGEN_STRONG_INLINE Packet4f pround<Packet4f>(const Packet4f& a) { return vec_round(a); }
|
||||||
|
@ -44,6 +44,11 @@
|
|||||||
#if __clang_major__ >= 3 && __clang_minor__ >= 5
|
#if __clang_major__ >= 3 && __clang_minor__ >= 5
|
||||||
#pragma clang diagnostic ignored "-Wabsolute-value"
|
#pragma clang diagnostic ignored "-Wabsolute-value"
|
||||||
#endif
|
#endif
|
||||||
|
#if ( defined(__ALTIVEC__) || defined(__VSX__) ) && __cplusplus < 201103L
|
||||||
|
// warning: generic selections are a C11-specific feature
|
||||||
|
// ignoring warnings thrown at vec_ctf in Altivec/PacketMath.h
|
||||||
|
#pragma clang diagnostic ignored "-Wc11-extensions"
|
||||||
|
#endif
|
||||||
|
|
||||||
#elif defined __GNUC__
|
#elif defined __GNUC__
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user