I’ve used mame4all (standalone, not retroarch core) for a couple years now on my original pi and never had any issues. But when I run the mame4all from the 2.6 RetroPie on my Pi 2 it has pretty significant audio issues: constant crackling, static, and choppy audio. These are the same roms that used to sound great when I ran them on my original Pi.
On squid’s mame4all page I found mention of uninstalling pulse audio if hdmi audio issues occur but pulse audio doesn’t seem to even be installed in RetroPie.
To be clear, I have no audio issues with any RetroArch cores. It’s just the standalone mame4all.
UPDATE: I just downloaded mame4all from the original source and tried running on my Pi 2:
https://sourceforge.net/projects/mame4allpi
And it sounds fine! So there’s something wrong with the mame4all standalone setup that RetroPie is providing. It should be the same version but perhaps there were some RetroPie modifications to the source or build process that are creating issues.