[linux-audio-user] Is everyone sick of interrupts yet?

Lee Revell rlrevell at joe-job.com
Tue Sep 28 21:23:50 EDT 2004


On Tue, 2004-09-28 at 18:05, Mark Knecht wrote:
> Lee Revell wrote:
> > On Tue, 2004-09-28 at 16:11, Mark Knecht wrote: 
> >>Lee Revell wrote:

> >>>I get no xruns at 32 (!) frames using 2.6 with the VP patches,
> >>>and my soundcard shares an interrupt with USB:
> >>>
> >>
> >>(Non-argumentive if it's unclear) Please stick a USB mouse on the USB 
> >>port that is shared and wiggle it madly while doing some of this. Can 
> >>you create an xrun?
> >>> 
> > 
> > No, this does not cause an xrun, because even though the USB interrupt
> > handler interrupts the soundcard irq (and vice versa), it does not run
> > for a significant fraction of the period time.  Of course it's best to
> > have the soundcard on an interrupt that is not shared.  But whether that
> > interrupt is #5 or #10 does not matter.
> 
> Great. Just checking. (You did *actually* do it, right?) ;-)

Ok, I repeated this test just now (I had actually done it, but weeks
ago).  It does not make a difference at all if I plug the mouse into the
front USB port (shared with the soundcard) or the rear one (not shared).

This is with the soundcard and mouse on different IRQs:

load = 1.3880 max usecs: 7.000, spare = 659.000
load = 1.2195 max usecs: 7.000, spare = 659.000
load = 1.1353 max usecs: 7.000, spare = 659.000
load = 1.8439 max usecs: 17.000, spare = 649.000 <-- start moving mouse
load = 1.6727 max usecs: 10.000, spare = 656.000
load = 2.3379 max usecs: 20.000, spare = 646.000
load = 2.5954 max usecs: 19.000, spare = 647.000 <-- stop moving mouse
load = 1.8983 max usecs: 8.000, spare = 658.000
load = 1.4747 max usecs: 7.000, spare = 659.000
load = 1.2629 max usecs: 7.000, spare = 659.000

Here is the mouse and soundcard sharing an IRQ:

load = 1.2021 max usecs: 8.000, spare = 658.000
load = 1.2017 max usecs: 8.000, spare = 658.000
load = 1.2014 max usecs: 8.000, spare = 658.000
load = 1.8770 max usecs: 17.000, spare = 649.000 <-- start moving mouse
load = 2.4400 max usecs: 20.000, spare = 646.000
load = 2.7215 max usecs: 20.000, spare = 646.000
load = 2.7121 max usecs: 18.000, spare = 648.000 <-- stop moving mouse
load = 1.9567 max usecs: 8.000, spare = 658.000
load = 1.5789 max usecs: 8.000, spare = 658.000
load = 1.3901 max usecs: 8.000, spare = 658.000

So, the interrupt response is about a microsecond faster with them on
different IRQs.  This is what I expected (but I did not expect it to
show up in jackd -v!).  And, regardless of whether the interrupt is
shared, mouse activity will only delay jackd by about 20 microseconds.

These numbers all support my original point that tweaking your
interrupts is a waste of time, you should be installing a low latency
kernel instead...

rlrevell at mindpipe:~$ uname -r
2.6.9-rc2-mm3-VP-S6

Lee




More information about the Linux-audio-user mailing list