HighCPU

Revision 1 as of 2009-01-12 19:00:06

Clear message

On occasion top might report high CPU usage associated with X. We get numerous bug reports about this. There are a number of causes:

Client Applications

In general, most CPU loads are driven by client applications overtaxing the server. Thus, in a way the X load is the sum of client application loads. For instance, the program might be making resource-intensive xlib calls in a tight loop. In almost all such cases, closing the offending program will cause the X load to go back to normal.

Software Rasterizing

Most modern graphics hardware has the ability to perform graphics calculations such as image rasterizing. In theory, X's graphics drivers would rely on the hardware when it needs to do these kinds of calculations, but this is not always the case. When it does them in software rather than hardware, you will see higher CPU loads in X. Check for this via glxinfo:

  $ glxinfo | grep render

  direct rendering: Yes
  OpenGL renderer string: Software Rasterizer

High CPU loads will be noted under this condition especially when moving windows, scrolling in firefox, and when compiz is enabled.

X Server Bug

Rarely, sometimes the high CPU can be due to X itself. In a normal, quiescent desktop system, X will require less than 10% of the CPU load.