commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] [gnuradio] 06/14: volk: using hypot instead of cabsf.


From: git
Subject: [Commit-gnuradio] [gnuradio] 06/14: volk: using hypot instead of cabsf.
Date: Thu, 12 Mar 2015 19:38:13 +0000 (UTC)

This is an automated email from the git hooks/post-receive script.

trondeau pushed a commit to branch android
in repository gnuradio.

commit 86d29d2e8ddccdf1710f94229e4493a97fce0ca6
Author: Tom Rondeau <address@hidden>
Date:   Sun Dec 21 10:43:20 2014 -0500

    volk: using hypot instead of cabsf.
    
    Android (API 21) does not support cabsf (known bug); hypot does the same 
thing and benchmark shows no change in speed.
---
 volk/kernels/volk/volk_32fc_s32fc_x2_rotator_32fc.h | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/volk/kernels/volk/volk_32fc_s32fc_x2_rotator_32fc.h 
b/volk/kernels/volk/volk_32fc_s32fc_x2_rotator_32fc.h
index 0650078..ee7d981 100644
--- a/volk/kernels/volk/volk_32fc_s32fc_x2_rotator_32fc.h
+++ b/volk/kernels/volk/volk_32fc_s32fc_x2_rotator_32fc.h
@@ -51,7 +51,8 @@ static inline void 
volk_32fc_s32fc_x2_rotator_32fc_generic(lv_32fc_t* outVector,
 #ifdef __cplusplus
         (*phase) /= std::abs((*phase));
 #else
-        (*phase) /= cabsf((*phase));
+        //(*phase) /= cabsf((*phase));
+        (*phase) /= hypotf(lv_creal(*phase), lv_cimag(*phase));
 #endif
     }
     for(i = 0; i < num_points%ROTATOR_RELOAD; ++i) {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]