[prev in list] [next in list] [prev in thread] [next in thread] 

List:       rockbox-dev
Subject:    Re: Profiling the codecs
From:       Tomasz Malesinski <tmal () mimuw ! edu ! pl>
Date:       2007-02-04 19:01:50
Message-ID: 20070204190150.GB3401 () duch ! mimuw ! edu ! pl
[Download RAW message or body]

> I notice that on mpa 5.7 and on vorbis a whopping 7.3% of CPU time is
> spent in switch_thread.  Can you by chance try turning off priority
> scheduling and see how that impacts those percentages?  That seems like
> an awefully high scheduling overhead.

I tried switching off HAVE_PRIORITY_SCHEDULING in
firmware/export/config.h and it doesn't make a big difference. With
mp3 playing, the number of cycles spent in switch_thread decreased
from 14.5M to 13.5M. When I slowed down the audio DMA in the emulator,
so that the codec thread had to wait once in a while for space in the
audio buffer, the number of cycles spent in switch_thread increased to
36M with no priority scheduling and 41M with it.

My benchmark is simply the boot process and playing 5s of audio (it
happens automaticaly, I play the song instead of calling browse_root
in apps/main.c). I haven't traced where most of switch_thread calls
come from.

-- 
Tomek Malesinski

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic