Skip to content

Commit

Permalink
Merge pull request gnuradio#656 from argilo/sixteenth-eighth
Browse files Browse the repository at this point in the history
Fix variable name in dot product kernels
  • Loading branch information
jdemel authored Oct 22, 2023
2 parents 72d44fd + 3fc09b3 commit 54f1539
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
12 changes: 6 additions & 6 deletions kernels/volk/volk_16i_32fc_dot_prod_32fc.h
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ static inline void volk_16i_32fc_dot_prod_32fc_u_sse(lv_32fc_t* result,
{

unsigned int number = 0;
const unsigned int sixteenthPoints = num_points / 8;
const unsigned int eighthPoints = num_points / 8;

float res[2];
float *realpt = &res[0], *imagpt = &res[1];
Expand All @@ -163,7 +163,7 @@ static inline void volk_16i_32fc_dot_prod_32fc_u_sse(lv_32fc_t* result,
__m128 dotProdVal2 = _mm_setzero_ps();
__m128 dotProdVal3 = _mm_setzero_ps();

for (; number < sixteenthPoints; number++) {
for (; number < eighthPoints; number++) {

m0 = _mm_set_pi16(*(aPtr + 3), *(aPtr + 2), *(aPtr + 1), *(aPtr + 0));
m1 = _mm_set_pi16(*(aPtr + 7), *(aPtr + 6), *(aPtr + 5), *(aPtr + 4));
Expand Down Expand Up @@ -212,7 +212,7 @@ static inline void volk_16i_32fc_dot_prod_32fc_u_sse(lv_32fc_t* result,
*realpt += dotProductVector[2];
*imagpt += dotProductVector[3];

number = sixteenthPoints * 8;
number = eighthPoints * 8;
for (; number < num_points; number++) {
*realpt += ((*aPtr) * (*bPtr++));
*imagpt += ((*aPtr++) * (*bPtr++));
Expand Down Expand Up @@ -422,7 +422,7 @@ static inline void volk_16i_32fc_dot_prod_32fc_a_sse(lv_32fc_t* result,
{

unsigned int number = 0;
const unsigned int sixteenthPoints = num_points / 8;
const unsigned int eighthPoints = num_points / 8;

float res[2];
float *realpt = &res[0], *imagpt = &res[1];
Expand All @@ -440,7 +440,7 @@ static inline void volk_16i_32fc_dot_prod_32fc_a_sse(lv_32fc_t* result,
__m128 dotProdVal2 = _mm_setzero_ps();
__m128 dotProdVal3 = _mm_setzero_ps();

for (; number < sixteenthPoints; number++) {
for (; number < eighthPoints; number++) {

m0 = _mm_set_pi16(*(aPtr + 3), *(aPtr + 2), *(aPtr + 1), *(aPtr + 0));
m1 = _mm_set_pi16(*(aPtr + 7), *(aPtr + 6), *(aPtr + 5), *(aPtr + 4));
Expand Down Expand Up @@ -489,7 +489,7 @@ static inline void volk_16i_32fc_dot_prod_32fc_a_sse(lv_32fc_t* result,
*realpt += dotProductVector[2];
*imagpt += dotProductVector[3];

number = sixteenthPoints * 8;
number = eighthPoints * 8;
for (; number < num_points; number++) {
*realpt += ((*aPtr) * (*bPtr++));
*imagpt += ((*aPtr++) * (*bPtr++));
Expand Down
12 changes: 6 additions & 6 deletions kernels/volk/volk_32fc_32f_dot_prod_32fc.h
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ static inline void volk_32fc_32f_dot_prod_32fc_a_sse(lv_32fc_t* result,
{

unsigned int number = 0;
const unsigned int sixteenthPoints = num_points / 8;
const unsigned int eighthPoints = num_points / 8;

float res[2];
float *realpt = &res[0], *imagpt = &res[1];
Expand All @@ -284,7 +284,7 @@ static inline void volk_32fc_32f_dot_prod_32fc_a_sse(lv_32fc_t* result,
__m128 dotProdVal2 = _mm_setzero_ps();
__m128 dotProdVal3 = _mm_setzero_ps();

for (; number < sixteenthPoints; number++) {
for (; number < eighthPoints; number++) {

a0Val = _mm_load_ps(aPtr);
a1Val = _mm_load_ps(aPtr + 4);
Expand Down Expand Up @@ -328,7 +328,7 @@ static inline void volk_32fc_32f_dot_prod_32fc_a_sse(lv_32fc_t* result,
*realpt += dotProductVector[2];
*imagpt += dotProductVector[3];

number = sixteenthPoints * 8;
number = eighthPoints * 8;
for (; number < num_points; number++) {
*realpt += ((*aPtr++) * (*bPtr));
*imagpt += ((*aPtr++) * (*bPtr++));
Expand Down Expand Up @@ -698,7 +698,7 @@ static inline void volk_32fc_32f_dot_prod_32fc_u_sse(lv_32fc_t* result,
{

unsigned int number = 0;
const unsigned int sixteenthPoints = num_points / 8;
const unsigned int eighthPoints = num_points / 8;

float res[2];
float *realpt = &res[0], *imagpt = &res[1];
Expand All @@ -715,7 +715,7 @@ static inline void volk_32fc_32f_dot_prod_32fc_u_sse(lv_32fc_t* result,
__m128 dotProdVal2 = _mm_setzero_ps();
__m128 dotProdVal3 = _mm_setzero_ps();

for (; number < sixteenthPoints; number++) {
for (; number < eighthPoints; number++) {

a0Val = _mm_loadu_ps(aPtr);
a1Val = _mm_loadu_ps(aPtr + 4);
Expand Down Expand Up @@ -759,7 +759,7 @@ static inline void volk_32fc_32f_dot_prod_32fc_u_sse(lv_32fc_t* result,
*realpt += dotProductVector[2];
*imagpt += dotProductVector[3];

number = sixteenthPoints * 8;
number = eighthPoints * 8;
for (; number < num_points; number++) {
*realpt += ((*aPtr++) * (*bPtr));
*imagpt += ((*aPtr++) * (*bPtr++));
Expand Down

0 comments on commit 54f1539

Please sign in to comment.