aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2011-02-07 16:41:21 +0100
committerGravatar Gael Guennebaud <g.gael@free.fr>2011-02-07 16:41:21 +0100
commitc5c8efa575038fc2e428c17c60050f7abfbb7a1b (patch)
tree86052455c38b2e1b23689ceca053b84fb980f97e /Eigen
parent9105e62d0a39d3a3e7864622fed5c393b25693a6 (diff)
workaround gcc 4.2 and 4.3 compilation issue with NEON
Diffstat (limited to 'Eigen')
-rw-r--r--Eigen/src/Core/arch/NEON/PacketMath.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/Eigen/src/Core/arch/NEON/PacketMath.h b/Eigen/src/Core/arch/NEON/PacketMath.h
index d826e969b..536fea3e0 100644
--- a/Eigen/src/Core/arch/NEON/PacketMath.h
+++ b/Eigen/src/Core/arch/NEON/PacketMath.h
@@ -84,6 +84,14 @@ template<> struct packet_traits<int> : default_packet_traits
};
};
+#if (defined __GNUC__) && (!(EIGEN_GNUC_AT_LEAST(4,4)))
+// workaround gcc 4.2 and 4.3 compilatin issue
+EIGEN_STRONG_INLINE float32x4_t vld1q_f32(const float* x) { return ::vld1q_f32((const float32_t*)x); }
+EIGEN_STRONG_INLINE float32x2_t vld1_f32 (const float* x) { return ::vld1_f32 ((const float32_t*)x); }
+EIGEN_STRONG_INLINE void vst1q_f32(float* to, float32x4_t from) { ::vst1q_f32((float32_t*)to,from); }
+EIGEN_STRONG_INLINE void vst1_f32 (float* to, float32x2_t from) { ::vst1_f32 ((float32_t*)to,from); }
+#endif
+
template<> struct unpacket_traits<Packet4f> { typedef float type; enum {size=4}; };
template<> struct unpacket_traits<Packet4i> { typedef int type; enum {size=4}; };