Closed codingkeith closed 7 years ago
KFR always uses unaligned load/store instructions because on the modern systems this hasn't any impact on performance. If the actual pointer is unaligned, it's ok to use unaligned instruction. If the actual pointer is aligned, unaligned instruction is as fast as aligned on the modern systems.
So this is not issue. Moreover, splitting argument_first can cause slowdown if the source expression isn't univector.
If using an input expression that reads from aligned memory, you will get an unaligned memory read on this line: https://github.com/kfrlib/kfr/blob/master/include/kfr/dsp/biquad.hpp#L196 (depending on the value of Filters)
Original code:
Suggested fix: