XBMC: Fix for 100% CPU usage when idle in menus

This is something that's had me baffled for some time. It just didn't make sense that CPU usage was barely 9% during video playback, but when it's paused or a menu is shown the damn thing would cook the computer!

It isn't very noticeable when switching between episodes/movies/shows but if I fall asleep before a movie finishes, I'd definitely be woken up by the busy CPU fan when my HTPC tries to stop itself from roasting in the TV unit.

HTPC, meet heat and XBMC.

A little research quickly shows that XBMC still carries a lot of legacy code from it's XBOX days, and redrawing the interface at every given chance is just one of those things.

This means XBMC is written with "game loop" logic in mind, so they had to add some options in order to optimise the redrawing process.

Thankfully there is a fairly easy way to fix this (possible since Eden or Frodo I beleive).

  • Make sure XBMC is NOT running.
  • Open up Windows Explorer and go to "%APPDATA%\XBMC\userdata\" (or ~/.xbmc/userdata/ on Linux)
  • If "advancedsettings.xml" doesn't already exist, create a file called and open it with Notepad.
  • Under the <gui> tag, copy in <algorithmdirtyregions> and <nofliptimeout> as shown below.
  • Save and exit.

I've tried the default "1000" value for <nofliptimeout> as shown in the XBMC docs but it didn't seem to have any effect. Only when I set it to "0" would it reduce CPU usage.

And of course, your mileage may vary depending on your graphics card and/or drivers installed. For my Intel E6700 (Core 2 Duo) and AMD A8-5600k it worked like a charm.


Copyright © Twig's Tech Tips
Theme by BloggerThemes & TopWPThemes Sponsored by iBlogtoBlog