From cb83e1ce4280f84d85eb7d7b6c17179b57f20d98 Mon Sep 17 00:00:00 2001 From: Tom Rondeau Date: Sat, 9 Apr 2016 13:58:24 -0400 Subject: [PATCH] volk_32f{c}_index_max_16u: changed output variable from unsigned int to unsigned short to match the function name. --- kernels/volk/volk_32f_index_max_16u.h | 16 ++++++++-------- kernels/volk/volk_32fc_index_max_16u.h | 10 +++++----- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/kernels/volk/volk_32f_index_max_16u.h b/kernels/volk/volk_32f_index_max_16u.h index 9d985a50e..94ac317a7 100644 --- a/kernels/volk/volk_32f_index_max_16u.h +++ b/kernels/volk/volk_32f_index_max_16u.h @@ -29,7 +29,7 @@ * * Dispatcher Prototype * \code - * void volk_32f_index_max_16u_a_sse4_1(unsigned int* target, const float* src0, unsigned int num_points) + * void volk_32f_index_max_16u(unsigned short* target, const float* src0, unsigned int num_points) * \endcode * * \b Inputs @@ -44,7 +44,7 @@ * int N = 10; * unsigned int alignment = volk_get_alignment(); * float* in = (float*)volk_malloc(sizeof(float)*N, alignment); - * uint32_t* out = (uint32_t*)volk_malloc(sizeof(uint32_t), alignment); + * uint16_t* out = (uint16_t*)volk_malloc(sizeof(uint16_t), alignment); * * for(unsigned int ii = 0; ii < N; ++ii){ * float x = (float)ii; @@ -73,7 +73,7 @@ #include static inline void -volk_32f_index_max_16u_a_sse4_1(unsigned int* target, const float* src0, unsigned int num_points) +volk_32f_index_max_16u_a_sse4_1(unsigned short* target, const float* src0, unsigned int num_points) { if(num_points > 0){ unsigned int number = 0; @@ -123,7 +123,7 @@ volk_32f_index_max_16u_a_sse4_1(unsigned int* target, const float* src0, unsigne max = src0[number]; } } - target[0] = (unsigned int)index; + target[0] = (unsigned short)index; } } @@ -135,7 +135,7 @@ volk_32f_index_max_16u_a_sse4_1(unsigned int* target, const float* src0, unsigne #include static inline void -volk_32f_index_max_16u_a_sse(unsigned int* target, const float* src0, unsigned int num_points) +volk_32f_index_max_16u_a_sse(unsigned short* target, const float* src0, unsigned int num_points) { if(num_points > 0){ unsigned int number = 0; @@ -186,7 +186,7 @@ volk_32f_index_max_16u_a_sse(unsigned int* target, const float* src0, unsigned i max = src0[number]; } } - target[0] = (unsigned int)index; + target[0] = (unsigned short)index; } } @@ -196,11 +196,11 @@ volk_32f_index_max_16u_a_sse(unsigned int* target, const float* src0, unsigned i #ifdef LV_HAVE_GENERIC static inline void -volk_32f_index_max_16u_generic(unsigned int* target, const float* src0, unsigned int num_points) +volk_32f_index_max_16u_generic(unsigned short* target, const float* src0, unsigned int num_points) { if(num_points > 0){ float max = src0[0]; - unsigned int index = 0; + unsigned short index = 0; unsigned int i = 1; diff --git a/kernels/volk/volk_32fc_index_max_16u.h b/kernels/volk/volk_32fc_index_max_16u.h index 72eff7e0c..c5944fdc5 100644 --- a/kernels/volk/volk_32fc_index_max_16u.h +++ b/kernels/volk/volk_32fc_index_max_16u.h @@ -30,7 +30,7 @@ * * Dispatcher Prototype * \code - * void volk_32fc_index_max_16u_a_sse3(unsigned int* target, lv_32fc_t* src0, unsigned int num_points) + * void volk_32fc_index_max_16u(unsigned short* target, lv_32fc_t* src0, unsigned int num_points) * \endcode * * \b Inputs @@ -47,7 +47,7 @@ * int N = 10; * unsigned int alignment = volk_get_alignment(); * lv_32fc_t* in = (lv_32fc_t*)volk_malloc(sizeof(lv_32fc_t)*N, alignment); - * uint32_t* max = (uint32_t*)volk_malloc(sizeof(uint32_t), alignment); + * uint16_t* max = (uint16_t*)volk_malloc(sizeof(uint16_t), alignment); * * for(unsigned int ii = 0; ii < N/2; ++ii){ * float real = 2.f * ((float)ii / (float)N) - 1.f; @@ -80,7 +80,7 @@ #include static inline void -volk_32fc_index_max_16u_a_sse3(unsigned int* target, lv_32fc_t* src0, +volk_32fc_index_max_16u_a_sse3(unsigned short* target, lv_32fc_t* src0, unsigned int num_points) { const unsigned int num_bytes = num_points*8; @@ -227,14 +227,14 @@ volk_32fc_index_max_16u_a_sse3(unsigned int* target, lv_32fc_t* src0, #ifdef LV_HAVE_GENERIC static inline void - volk_32fc_index_max_16u_generic(unsigned int* target, lv_32fc_t* src0, + volk_32fc_index_max_16u_generic(unsigned short* target, lv_32fc_t* src0, unsigned int num_points) { const unsigned int num_bytes = num_points*8; float sq_dist = 0.0; float max = 0.0; - unsigned int index = 0; + unsigned short index = 0; unsigned int i = 0;