jgaeddert / liquid-dsp

digital signal processing library for software-defined radios
http://liquidsdr.org
MIT License
1.82k stars 426 forks source link

FYI: NCO Constrain previously had invalid results on ARM #223

Open brian-armstrong opened 3 years ago

brian-armstrong commented 3 years ago

Hello,

It looks like prior to https://github.com/jgaeddert/liquid-dsp/commit/f415521f9e5505d318385755554701552bbdd58a#diff-fe503c82f2e39633d33b9e831d08b92999123815a7ac0e61488eec28b43b7b34 , constrain produced invalid results on ARM. This is because converting a negative floating point number to an unsigned integer produces 0 on ARM. I looked through issues but I couldn't tell if you knew this and that's why the fix was applied.

This is quite likely the issue behind https://github.com/jgaeddert/liquid-dsp/issues/160 and https://github.com/jgaeddert/liquid-dsp/issues/146 .

Any liquid-dsp users who might operate on ARM should strongly consider upgrading.

Cheers!

jgaeddert commented 3 years ago

Hey, thanks! I hadn't realized this off hand, but I did notice a decent number of issues on various systems. I still don't love how the NCO operates, and have aspirations to streamline it on several fronts, but am ok pushing it to the back burner until it becomes a hot issue again (to keep the metaphor alive)!