[alsa-devel] pulseaudio eats 19% CPU power in Fedora 12

Colin Guthrie gmane at colin.guthr.ie
Wed Apr 21 09:57:28 CEST 2010

'Twas brillig, and Raymond Yau at 21/04/10 01:30 did gyre and gimble:
> 2010/4/19 Daniel Chen <seven.steps at gmail.com>
>>  but, like
>> Lennart suggests, these are by no means *caused* by PulseAudio.
>> Best,
>> -Dan
> There are other factor affecting CPU usage  significantly
> 1) the number of pulseaudio clients connected to PA server (i.e. number of
> audio stream need to be mixed )
> 2) the accuracy of system timer and the clock of the sound chip
> 3) the latency requirement of the different PA clients
> 4) the resampling method
> 5) the cpu loading of the system
> 6) the period time/period size selected by PA server to configure the alsa
> driver
> why do you ruled out the cause ?
>>> If you use "pacat" you can play audio with almost zero CPU
> usage
> do you get the zero CPU usage in  Ubuntu 9.04/Ubuntu 9.10 with pacat on your
> machines ?

The pacat support for proper latency adjustment is only available in
more recent PA versions (with some , so chances are the older distros
wont have them (although I believe a 9.10 version of 0.9.21+stable-queue
exists somewhere.

These commits from stable-queue are certainly needed:

commit 19fa81bf1375032cb1a27c7715a28a52b238d4cb
Author: Lennart Poettering <lennart at poettering.net>
Date:   Thu Feb 18 01:54:51 2010 +0100

    pacat: always fully fulfill write requests

    Make sure we always fulfill write requests from the server. If we don't
    the server won't ask us again and playback will stay stuck.


and this one (although it's not problematic for playback):

commit b2e9fb6f6e12a3eab8a41c67017507e60d616e2a
Author: Lennart Poettering <lennart at poettering.net>
Date:   Sun Feb 21 21:09:26 2010 +0100

    pacat: pass buffer_attr to recording streams too

    Pointed out by Colin Guthrie.



Colin Guthrie

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mandriva Linux Contributor [http://www.mandriva.com/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]

More information about the Alsa-devel mailing list