From 40c161c2e6f74ed62765d7a6767f8d4a98295a8f Mon Sep 17 00:00:00 2001 From: Ismael Gomez Date: Fri, 20 Jan 2017 11:50:16 +0100 Subject: [PATCH] ifdef for simd functions --- srslte/lib/utils/vector_simd.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/srslte/lib/utils/vector_simd.c b/srslte/lib/utils/vector_simd.c index 01a3d4c64..c150209ca 100644 --- a/srslte/lib/utils/vector_simd.c +++ b/srslte/lib/utils/vector_simd.c @@ -314,6 +314,7 @@ void srslte_vec_sum_fff_simd(float *x, float *y, float *z, uint32_t len) { #endif } +#ifdef LV_HAVE_SSE static inline __m128 _mm_complexmul_ps(__m128 x, __m128 y) { __m128 yl, yh, tmp1, tmp2; yl = _mm_moveldup_ps(y); // Load yl with cr,cr,dr,dr @@ -323,6 +324,7 @@ static inline __m128 _mm_complexmul_ps(__m128 x, __m128 y) { tmp2 = _mm_mul_ps(x, yh); // tmp2 = ai*ci,ar*ci,bi*di,br*di return _mm_addsub_ps(tmp1, tmp2); // ar*cr-ai*ci, ai*cr+ar*ci, br*dr-bi*di, bi*dr+br*di } +#endif void srslte_vec_prod_ccc_simd(cf_t *x,cf_t *y, cf_t *z, uint32_t len) { @@ -352,11 +354,13 @@ void srslte_vec_prod_ccc_simd(cf_t *x,cf_t *y, cf_t *z, uint32_t len) #endif } +#ifdef LV_HAVE_SSE static inline __m128 _mm_complexmulconj_ps(__m128 x, __m128 y) { const __m128 conjugator = _mm_setr_ps(0, -0.f, 0, -0.f); y = _mm_xor_ps(y, conjugator); return _mm_complexmul_ps(x, y); } +#endif void srslte_vec_prod_conj_ccc_simd(cf_t *x,cf_t *y, cf_t *z, uint32_t len) { #ifdef LV_HAVE_SSE