I decided to change the title to make it more relevant. I wasn't sure where to post the following yet as I was keen to share it in case this helps others.
We ran into a very painful issue while testing a recent build of DOSBox Staging. The sound was crackling like hell in almost every games tested and only pi4 platform was affected (pi3 was ok). Builds for macOS, x86, etc didn't have the issue either. After a long and rather difficult debugging session the culprit has been found (thanks to @kcgen!) > SpeexDSP's floating-point API is unreliable on current (32-bit) Buster. After compiling our own version everything went back to normal.