[mythtv] Mac OS X speed decrease between 0.15 and CVS

Jeremiah Morris jm at whpress.com
Fri Oct 22 14:36:37 UTC 2004


On 22 Oct 2004, at 6:59 AM, Ben de Luca wrote:

> shark looks like an awesome tool

I used Shark extensively this weekend, and it is incredibly cool.  
Shark is what allowed me to find the usleep bug with Live TV that just 
got fixed in CVS.

I also found some other slowdowns; Nigel, you might want to try these 
and see if your situation improves.

- Around lines 1177-1192 of tv_play.cpp, there's code to update the LCD 
display.  This code accounted for 15% of the frontend's time on my box 
(just the time calculations for deciding whether to update the LCD took 
about half of that).  I commented out that section and got a 
significant boost in speed.  I'm really hoping that the LCD support is 
made conditional soon.

- Around line 1694 of NuppelVideoPlayer.cpp, the video output thread 
requests realtime priority.  This seems to succeed on OS X even without 
SUID root (maybe when run under an administrator account?), but I found 
it might actually hurt performance.  I haven't done thorough tests on 
the latest version, so I can't give numbers, but it's worth a try.

With these changes, the latest patches, and some aggressive 
optimization flags, I got mythfrontend down to about 65% of my G4/800 
while playing 640x480 NTSC (29.97fps) video.  I didn't see other 
low-hanging fruit; from a discussion I sparked on the ffmpeg list, 
there are some Altivec optimizations to be had, but I don't understand 
that code so that's a ways off unless somebody else steps up.

> Just wondering if there is a list of OSX patches out there? that are 
> yet to be commited?

There's one huge bundle of them in the queue, but the end is in sight 
-- hopefully in the next few days Isaac or Donavan can get them into 
CVS.  If you hang tight for a little while, there should be very few 
uncommitted patches to wade through.

- Jeremiah



More information about the mythtv-dev mailing list