Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Audacious using > 50% cpu
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
aka.bugle
n00b
n00b


Joined: 11 Dec 2006
Posts: 57

PostPosted: Thu Jul 12, 2007 6:12 pm    Post subject: Audacious using > 50% cpu Reply with quote

It took a bit to get Alsa going but I've got a nice little gentoo install on a 200mhz Pentium mmx laptop running w/ gnome.
It has a problematic ess1879 isa chip (card?) in it.

My 1st question is ... Should Audacious be using 50% cpu when playing mp3s? I've got all extraneous plugins turned off. even mouse movement will cause skipping! Audacious 1.3.2 plugins 1.3.5

gsteamer is not functioning correctly yet.. I have sound to speakers but all audio files stall (like a record player skipping on the 1st note of the song.) hence no Rhythmbox, Quod Libet etc. The output test pipe for gsteamer's alsasink make a stuttering tone. The input pipe crashes the gstreamer setup.

If I use a program like Grip to play an audio cd , Grip only uses about 10% cpu. (plays and sounds fine, cddb works)
Audacious uses a similar 11-12% when playing audio cds. (plays and sound fine although cddb doesn't work????)

2nd question... what would be the least cpu intensive settings for audacious when playing compressed audio files (ogg, Mp3 , etc.)
Back to top
View user's profile Send private message
BradN
Advocate
Advocate


Joined: 19 Apr 2002
Posts: 2391
Location: Wisconsin (USA)

PostPosted: Fri Jul 13, 2007 1:39 am    Post subject: Reply with quote

Audacious will skip by itself on a pentium-133... I'd say 50% CPU usage on a p200-mmx is about par for the course. Turn off the equalizer if you have that on, and shut off resampling in the config.

Personally, I'd recommend a text mode program like mp3blaster or even command line only like mpg123/splay or ogg123... it sucks that xmms is no longer in portage. There's also MPD (music player daemon) which seems to use mpg123 and similar programs to actually play the audio, although I haven't tested it.

Another tip to reduce CPU usage is using a 16 bit sound card (not sure what bus a ess1879 operates with).

A little project I have going is seeing how much gentoo I can cram into the hard drives on some old pentiumish machines (1GB and 540MB) - my strategy is compiling on a faster machine, stripping out unnecessary-for-operation files (ie, no portage/compiling), compressing /usr into a squashfs image, and then rsyncing the whole thing to the target machine to update it.
Back to top
View user's profile Send private message
aka.bugle
n00b
n00b


Joined: 11 Dec 2006
Posts: 57

PostPosted: Fri Jul 13, 2007 2:55 am    Post subject: Reply with quote

Thanks for the tips!
Do you think that using OSS would offer a performance boost (less cpu intensive) ? i.e. dump alsa for oss to get gstreamer working?
the sound w/ alsa and audacious w/mp3 isn't bad but why does playing an mp3 cost so much more cpu than playing a cd????
This card is a ISA daughterboard (ESS Audiodrive es1879) it has vague documentation and googling gives lots of configuration issues with alsa. (i'm not giving up on gstreamer yet) My modules.d/alsa file may still be alittle off...

200 mhz laptop came w/ a 5 gig hard drive but i picked up a cheap 30 gig and off I went! This is my 1st gentoo install on a laptop. Compile times are s o S l o wwwww. it took about a week to compile gnome! but its really a great little machine! Do you think a i586 kernel source will be released in 2007? ( i'm using a 2006 kernel source.)
Back to top
View user's profile Send private message
BradN
Advocate
Advocate


Joined: 19 Apr 2002
Posts: 2391
Location: Wisconsin (USA)

PostPosted: Fri Jul 13, 2007 3:28 am    Post subject: Reply with quote

playing a CD is just basically copying data (digital mode) or completely CPU-free (via audio cable), but mp3 decoding actually takes processing power.

I'm not sure what you mean by an i586 kernel source - the kernel can be compiled for any processor you want with no special effort - just change it in the kernel config under "Processor type and features" -> "Processor family" and recompile it. If you mean a 586 CHOST gentoo install, this can be done, but you need to rebuild everything installed or things might break.

Steps for this:
* edit /etc/make.conf and change CFLAGS/CHOST to however you want it
* run /usr/portage/scripts/bootstrap.sh (rebuilds the compiler toolchain)
* emerge -e system (rebuilds system packages - I've had success skipping this step)
* emerge -e world (rebuilds everything in your world file and all of their dependencies)
* (optional) hunt around for old files in directories named with the old CHOST setting - they can be safely deleted, ie if you switch from i486 to i586, there will be a bunch of i486 things that gentoo doesn't want to remove automatically

As for oss vs alsa, there might be some slight gains in using oss, but I don't know if it'd be anything that significant. What surprised me is how badly 8 bit sound cards performed on a pentium 133 vs 16 bit ones, and I tested a couple of each - something like a 30% CPU usage difference in mpg123.
Back to top
View user's profile Send private message
aka.bugle
n00b
n00b


Joined: 11 Dec 2006
Posts: 57

PostPosted: Fri Jul 13, 2007 12:52 pm    Post subject: Reply with quote

Well by sources... I mean, when you first install, youchoose a stage 3, between generic i86, i586, i686, etc, ...
In the current directories (for gentoo 2007.0) http://gentoo.mirrors.pair.com/releases/x86/2007.0/stages/ there is no package for i586, only x86 or i686. but last years kernels there were specific i586 versions (...releases/x86/2006.1/stages/)
So my kernel is based on a last years stage... as there is no i586 stages in 2007 (yet?)

I emerged mp3blaster and it has the same "broken record" first note skips sound as in any gstreamer app. Only audacious plays Mp3s without this glitch.

my /etc/modules.d/alsa file
Code:
# Alsa kernel modules' configuration file.

# ALSA portion
# OSS/Free portion

##
## IMPORTANT:
## You need to customise this section for your specific sound card(s)
## and then run `update-modules' command.
## Read alsa-driver's INSTALL file in /usr/share/doc for more info.
##
##  ALSA portion
alias char-major-116 snd
alias char-major-14 soundcore

alias sound-slot-0 snd-card-0
alias snd-card-0 snd-es18xx
options snd-es18xx enable=1 isapnp=0 port=0x220 mpu_port=0x330 fm_port=0x388 dma1=1 dma2=3 irq=5

##  OSS/Free portion

alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-8 snd-seq-oss
alias sound-service-0-12 snd-pcm-oss

alias /dev/mixer snd-mixer-oss
alias /dev/dsp snd-pcm-oss
alias /dev/midi snd-seq-oss


my make.conf
Code:

# Please consult /etc/make.conf.example for a more detailed example

CHOST="i586-pc-linux-gnu"
CFLAGS="-march=pentium-mmx -O2 -pipe -fomit-frame-pointer"
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j2"

INPUT_DEVICES="keyboard mouse evdev synaptics"

VIDEO_CARDS="neomagic vesa vga"

ALSA_CARDS="es18xx"

FEATURES="parallel-fetch"

GENTOO_MIRRORS="ftp://ftp.ussg.iu.edu/pub/linux/gentoo http://gentoo.chem.wisc.edu/gentoo/ http://gentoo.mirrors.pair.com/ http://gentoo.mirrors.tds.net/gentoo http://gentoo.netnitco.net http://mirrors.acm.cs.rpi.edu/gentoo/ http://mirror.datapipe.net/gentoo http://gentoo.cites.uiuc.edu/pub/gentoo/ "
SYNC="rsync://rsync.gentoo.org/gentoo-portage"

PORTAGE_ELOG_CLASSES="info warn error"
PORTAGE_ELOG_SYSTEM="save"

PORTDIR_OVERLAY="/usr/local/portage"
PORTAGE_TMPDIR="/var/tmp/portage"

#-----------------------------
XUSE="truetype X new-login xorg xscreensaver xv xcomposite opengl aiglx"
IMAGEUSE="jpeg gif tiff png svg pdf"
MEDIAUSE="gstreamer alsa oss esd cddb mad asf win32codecs mp4 aac ogg vorbis nsplugin mp3 real wma tta sndfile"
GENERAL="java bzip2 symlink spell usb xml"
SYSTEM="hal fam dbus mmx threads"
NOTUSE="-arts -qt4 -ipv6"
KDEUSE="-kde -qt3"
GNOMEUSE="gtk cairo glitz gnome firefox pda"

USE="${NOTUSE} ${SYSTEM} ${GENERAL} ${IMAGEUSE} ${XUSE} ${KDEUSE} ${MEDIAUSE} ${GNOMEUSE}"
#------------------------------


see any clues?
Back to top
View user's profile Send private message
gimpel
Advocate
Advocate


Joined: 15 Oct 2004
Posts: 2720
Location: Munich, Bavaria

PostPosted: Fri Jul 13, 2007 6:10 pm    Post subject: Reply with quote

For audacious, also turn off the visualization in the player window (by clicking on it three times), that one eats a lot too.
_________________
http://proaudio.tuxfamily.org/wiki - pro-audio software overlay
Back to top
View user's profile Send private message
BradN
Advocate
Advocate


Joined: 19 Apr 2002
Posts: 2391
Location: Wisconsin (USA)

PostPosted: Fri Jul 13, 2007 7:14 pm    Post subject: Reply with quote

Hmm, I have no idea why the sound messes up, but using the procedure I posted above, you can recompile everything for 586, and it would be as if you installed using a 586 stage image - it's just a less convenient way.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum