Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 Dec 2004 15:10:33 -0800 (PST)
From:      Doug White <dwhite@gumbysoft.com>
To:        Krzysztof Kowalik <kkowalik@uci.agh.edu.pl>
Cc:        current@freebsd.org
Subject:   Re: FreeBSD sound distortion problems with SB Live! fixed with PREEMPTION
Message-ID:  <20041211141852.M72997@carver.gumbysoft.com>
In-Reply-To: <20041209172941.GA29369@uci.agh.edu.pl>
References:  <20041207234840.7287cdf4@maya.liquidx.org> <1102506431.1090.8.camel@taxman> <41B6ED4E.6030301@fer.hr> <20041209172941.GA29369@uci.agh.edu.pl>

next in thread | previous in thread | raw e-mail | index | archive | help
Okay, I'm testing this now ... so far no issues, unless I force things.

The system is currently running 5.3-STABLE built Dec 5.  The machine is an
Althon 3000+ (Barton) on a KT400-based Soyo using either the built-in CMI
audio or a PCI SBLive 5.1 Digital card.  SCHED_4BSD, no PREEMPTION, no
apic, no WITNESS/INVARIANTS.

I played a 160kb VBR MP3 with mpg321 (mpg123 was compiled to use esound on
this system so I decided to try something not so polluted) direct to each
card in turn with a -j3 buildworld running in the background, using the
same disk as the MP3s were located on.  I ran the buildworld in a Konsole
window on KDE 3.2.3 and played the mp3's in another.

I start getting wierdness when the load average hits 5+ with 0% idle.
Otherwise things hold up.

Interrupt layout:

zao,ttyp3,~,11>vmstat -i
interrupt                          total       rate
irq0: clk                         115654         99
irq1: atkbd0                        3131          2
irq5: fwohci0 uhci2                    2          0
irq6: fdc0                             9          0
irq8: rtc                         148030        127
irq10: pcm0 ehci0                  23453         20
irq11: vr0 uhci0                   23291         20
irq12: pcm1 uhci1                  20841         17
irq13: npx0                            1          0
irq14: ata0                        64869         56
irq15: ata1                           46          0
Total                             399327        344

During the test pcm0 is running at 600 interrupts/s and pcm1 is at a
measely 85 interrupts/s.

If you are getting distortion on an otherwise idle system I'll be more
interested, although that doesn't appear to be the case...

I'll repeat the runs after world finishes building & installing and see if
its something that changed in the last week.  I'd suggest that people
verify that their sound card isn't stuck on the same interrupt as a really
busy device or they aren't having a quiet interrupt storm going off
somewhere else or otherwise running things that chew CPU.

Of course, make sure WITNESS & INVARIANTS are removed from the running
kernel.  WITNESS is guaranteed to cause problems with sound; setting
'sysctl debug.witness.watch=0' should clear up problems immediately if you
have WITNESS compiled in.

phk's suggested that usb is a huge hog and sharing interrupts with a USB
controller could cause latency problems. I'll investigate this after the
buildworld finishes and I check if things are different than with last
week's build.

On Thu, 9 Dec 2004, Krzysztof Kowalik wrote:

> Ivan Voras [ivoras@fer.hr] wrote:
> > [...]
> > Not exactly a freeze, but PREEMPTION doesn't help me at all with SB Live
> > (slowdowns, stuttering sound, etc.), especially with large amounts of
> > filesystem operations (this is 5-stable).
>
> Exactly. I tried to use both emu10k1 and emu10kx drivers, with kernel
> with and without PREEMPTION, and both 5.x and 6.0 serie did behave same.
> Intensive I/O made the system quite unusable, and it was not only a
> sound-related issue, but a general one -- slow, lagging mouse in X, etc.
>
> I asked about it on stable@ and somehow got no answers but "me too".
>
> Finally, I decided to restore my 4.9 system from the backups, where the
> problem does not exist.
>
> Regards,
>

-- 
Doug White                    |  FreeBSD: The Power to Serve
dwhite@gumbysoft.com          |  www.FreeBSD.org



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20041211141852.M72997>