Profiling GNOME Shell

As of today, Mutter and GNOME Shell support Sysprof-based profiling.

Christian wrote a fantastic piece exposing what happened to Sysprof during this cycle already, and how does it look like now, so I’ll skip that.

Instead, let me focus on what I contributed the most: integrating Mutter/GNOME Shell to Sysprof.

Let’s start with a video:

Sysprof 3 profiling GNOME Shell in action

When it comes to drawing, GTK- and Clutter-based applications follow a settled cycle drawing cycle:

  • Size negotiation: position screen elements, allocates sizes;
  • Paint: draw the actual pixels;
  • Pick: find the element below the pointer;

What you see in the video above is a visual representation of this cycle happening inside GNOME Shell, although a bit more detailed.

With it, we can see when and why a frame was missed; what was probably happening when it occurs; and perhaps the most important aspect, we have actual metrics about how we’re performing.

Of course, there is room for improvements, but I’m sure this already is a solid first step. Even before landing, the profiling results already provided us with various insights of potential improvements. Good development tools like this result in better choices.

Enjoy!


3 responses to “Profiling GNOME Shell”

  1. Hii thanks for sharing this

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.