[pulseaudio-discuss] pulsesrc consumes much more CPU than alsasrc
Bin Gao
bin.gao at intel.com
Thu Mar 25 02:43:44 PDT 2010
Oh, I tested that on an Atom platform. Is that the cause?
-Bin
On Mon, 2010-03-15 at 05:12 -0600, Colin Guthrie wrote:
> Hi Bin,
>
> 'Twas brillig, and Bin Gao at 15/03/10 10:28 did gyre and gimble:
> > (resend as plain text)
>
> Nice :)
>
>
> > It seems both pulseaudio alsa PCM plugin (source) and gstreamer
> > pulsesrc consume much more CPU resource than alsa when working on the
> > same sample (rate, channel and format). I had a rough look at the source
> > code and found they both use the threaded mainloop model. Can we have
> > any chance to optimize for this?
>
>
> > $ gst-launch alsasrc device="hw:0,0" ! queue ! audioconvert ! wavenc !
> > filesink location=test.wav CPU% = 2~3%
>
> Trying here I get between 1 and 2% CPU.
>
>
> > $ gst-launch pulsesrc ! queue ! audioconvert ! wavenc ! filesink
> > location=test.wav CPU% = 12~14%
>
> Here I get about 4% CPU (one process hovered between 1 and 2%, with a
> second process hovering between 0 and 1% with a third most at 0 and very
> occasionally at 1% and a fourth always at 0%)
>
> So definitely less than optimal but not as striking as your example.
>
>
>
>
> (what was interesting to me was that running the first example via
> pasuspender caused the sinks/source to not unsuspend themselfs when I
> hit control + C... need to investigate that one).
>
> Col
>
>
More information about the pulseaudio-discuss
mailing list