Now that we have a Gjs profiler we can start looking at doing some fun things with it.
Today I wrote a couple line patch to GNOME Shell to toggle on and off the profiler using SIGUSR2. So if you build Gjs and gnome-shell with the appropriate patches, you can do something like:
gnome-shell --wayland # .. inside shell kill -SIGUSR2 <pid> # .. exercise shell a bit kill -SIGUSR2 <pid> # .. now look at /tmp/gjs-profile-$pid
It looks something like this.
Happy bug hunting!