summaryrefslogtreecommitdiff
path: root/gr-analog/python/analog/qa_sig_source.py
diff options
context:
space:
mode:
authorThomas Habets <thomas@habets.se>2020-06-07 18:52:22 +0100
committermormj <34754695+mormj@users.noreply.github.com>2020-06-15 08:21:35 -0400
commit518aa489498ec692dee51bb69936b620660ba113 (patch)
tree49ff128f6549ad7d91eb11020d85581f292f3f1b /gr-analog/python/analog/qa_sig_source.py
parentef825aad904b9a5ff99160d7f38181eb175137eb (diff)
blocks/moving_average: use vector functions
This improves performance of moving average for me by about 4-5x. My test is [here](https://github.com/ThomasHabets/radiostuff/blob/master/amateur/listen_70cm.grc), which processes 10MHz to find the strongest signal. Without this PR I see `moving_average` in `top` taking about 89.4-94% CPU. With this patch it's ~20.4-23.7%. Since without this patch it's that high, I don't know that it's not even better. Test measured on a Libremv2 with Intel Core i7-6500U @ 2.5GHz. The memory access pattern is probably worse with this patch, but at least on my hardware on my workload this seems to be dwarfed by the gain of using volk. It can be hard to reason about memory access patterns, so benchmarks overrule theory. The test only actually uses float averaging. More benchmarking may be required. Possible improvements: * Add template specialization for `uint16` and `uint32`? * Refactor for non-volk fallback to use only one loop, with (presumably) better memory access pattern)
Diffstat (limited to 'gr-analog/python/analog/qa_sig_source.py')
0 files changed, 0 insertions, 0 deletions