Hello folks! It has been another 3 months since our last update on the Firefox Profiler. During this time the Performance Tools team and our brilliant contributors have made many improvements that should make using the tool a more delightful experience.
Here are the highlights: # New Categorized Activity Timeline Perhaps the most prominent change is that the default graph format has changed. Instead of displaying a bar graph of the sampled stack length, the tool now shows the type of activity that occurred at a specific point in time (blue: DOM, purple: layout, green: graphics, yellow: JS, orange: GC/CC, gray: other, empty: idle). You can switch between the activity graph and the stack graph using the radio buttons above the thread & process list. # Navigate faster with the Loupe View For those used to timelines in movie editing software, there is an additional timeline view at the top of the call tree panel that combines the category view with an inverted stack chart view. You can use it to quickly navigate the selected thread’s timeline: shift+scroll to zoom, scroll to pan, click to focus the call tree on the selected area. # Dimmed idle stacks When selecting the traditional stack graph view, idle stacks are now dimmed, making it easier to focus on the profile areas that matter. # Grouped thread & track list The thread list has also been updated to group the main thread of each process with the other threads in the same process. Furthermore, there will be additional tracks for network traffic per process that focus the network panel on selection, where one can inspect the requests made in that process. The grouping and the extra tracks are also selectable in the context menu when right-clicking on the thread list, where you can also select to display any idle threads that are automatically hidden by default. Unhiding threads can be useful when one is interested in the 1% of non-idle activity that occurs in a predominantly idle thread. # Screenshot capturing (OSX only, more coming!) On macOS systems with Web Render disabled, the profiler add-on has an additional setting to capture screenshots of the open windows. This should help understand to what visual state of the browser the various events correspond. Support for more platforms will come in the future. # Filter across all panels All six bottom panels can now be filtered by specific strings that will limit the display to the stacks or markers containing said string. # Import native `perf` traces Two of the current limitations of the profiler are that it can’t profile the very early phase of browser startup (before the profiler code has been initialized) and that it imposes some small overhead when recording. The overhead increases when one increases the number of sampled threads. One nice workaround for both problems that still lets you use the profiler UI to investigate is recording a profile on Linux with the ‘perf’ tool and then importing the output from https://perf-html.io/. The profiler can parse the recorded profile and display the aggregated stacks (but of course without markers). To record a profile with the ‘perf’ command run the following commands and then load the firefox.symbol.data output file from https://perf-html.io: > sudo perf record -g -F 999 -p <firefox-bin-pid> > sudo perf script -F +pid > firefox.symbol.data # Remote profiling for Gecko on Android Finally, profiling Fennec or GeckoView nightlies has been improved, by removing the overhead imposed by devtools and adding symbols for native Android libraries. Documentation on remote profiling Android is available at https://perf-html.io/docs/#/./guide-remote-profiling We would like to encourage everyone to try these new features out and let us know of anything that we could improve. If you come across a performance bug while you are at it, please remember to file a bug and tag it with [qf] in the whiteboard. Our performance team will be happy to investigate. Happy profiling! Panos, on behalf of the perf tools team _______________________________________________ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform