[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [VOLK] a += b*c ?
From: |
Johannes Demel |
Subject: |
Re: [VOLK] a += b*c ? |
Date: |
Tue, 16 Aug 2022 14:13:59 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 |
Hi Randall,
in your case,
https://github.com/gnuradio/volk/blob/main/kernels/volk/volk_32f_x2_multiply_32f.h
followed by
https://github.com/gnuradio/volk/blob/main/kernels/volk/volk_32f_x2_add_32f.h
would be the way to go at the moment.
```
volk_32f_x2_multiply_32f(multiply_result, b, c, num_samples);
volk_32f_x2_add_32f(a, a, multiply_result, num_samples);
```
You're welcome to start a new kernel
```
volk_32f_x3_multiply_add_32f(out, a, b, c, num_samples);
```
In fact, it would be a great addition to VOLK.
Cheers
Johannes
On 16.08.22 01:38, Randall Wayth wrote:
Thanks for the suggestions and apologies for not being 100% clear at the
start.
I'm not looking for a dot product. I'm looking for
a[i] += b[i]*c[i] specifically for floating point
So it would be the equivalent of IPP's ippsAddProduct_32f.
The application is to apply a window to a set of samples before
accumulating, to implement a weighted overlap add PFB. In my case the
samples are real-valued, but I could also see a case for a and b being
complex, or the case for b being 8 or 16-bit ints with a and c being
floating point.
Cheers,
Randall
smime.p7s
Description: S/MIME Cryptographic Signature