[mythtv-commits] Ticket #6656: Frontend uses 100% CPU when paused

MythTV mythtv at cvs.mythtv.org
Fri Jun 26 21:46:37 UTC 2009


#6656: Frontend uses 100% CPU when paused
-------------------------------------+--------------------------------------
 Reporter:  anonymous                |        Owner:  ijr           
     Type:  defect                   |       Status:  infoneeded_new
 Priority:  minor                    |    Milestone:  0.22          
Component:  MythTV - Video Playback  |      Version:  head          
 Severity:  medium                   |   Resolution:                
  Mlocked:  0                        |  
-------------------------------------+--------------------------------------

Comment(by gnome42):

 Replying to [comment:4 anonymous]:
 > Thanks for checking.  I tried again with -v all, and there's tons of
 logs, but as you suspected, everything stops during the pause.
 >
 > But... I went looking at the code and found this:
 >
 > NuppelVideoPlayer.cpp:
 > 3695:         if (paused)
 > ...
 > 3732:                 //printf("startplaying waiting for unpause\n");
 > 3733:                 usleep(500);
 >
 > Things improve if I set it to usleep(1000) - i.e. 1ms.  Is there a
 reason this sleep interval is so short?

 Not that I'm aware of and it does seem to be a very short sleep for being
 paused. I wonder why more people aren't seeing high cpu usage when paused.

 Change sets touching that area are ancient so I imagine it might just be
 some bitrot.

 It looks like a power wasting, BBQ feature and we ain't gettin' no steaks
 out of it! Your frontend should be using zero cpu when paused, IMHO. How
 large do you have to make that sleep to achieve that? (5 or 10ms perhaps?)

 Good find, and thanks for digging into it!

-- 
Ticket URL: <http://svn.mythtv.org/trac/ticket/6656#comment:5>
MythTV <http://www.mythtv.org/>
MythTV


More information about the mythtv-commits mailing list