[LAU] Linux audio app design: The nature of xruns

Dominic Sacré dominic.sacre at gmx.de
Mon Dec 28 18:45:44 EST 2009


On Monday 28 of December 2009 21:08:05 Arnold Krille wrote:
> > I don't know about Qarecord, but unfortunately JackMix is an
> > example of a JACK app that does not "follow the rules".
>
> Interesting. Do you care to explain that?

In JackMix::process(), two QMaps are created and filled with objects 
(every single time the callback is invoked). I didn't look at the 
implementation of QMap, but I don't see how this could work without 
dynamic memory allocations happening somewhere.
In this particular case, I'd expect memory to be allocated for the 
storage of the map elements, and probably for the content of the 
QStrings (which are used as map keys) as well.

That said, I have no conclusive evidence to prove that any of the xruns 
I've seen in the past were actually JackMix's fault. The real problem 
might have been elsewhere.

I also use a lot of STL and various Boost libraries in my own JACK 
projects (including the realtime parts), so I know how painful it can be 
to figure out which parts of some convoluted template classes are "safe" 
to use...


Dominic


PS: the jackmix-0.4.1.tar.gz tarball seems to be gzipped twice, so tar 
can't open it without gunzipping it first...



More information about the Linux-audio-user mailing list