Related to this unsolved mystery: apple.stackexchange.com/questions/62416/why-do-i-get-serious-execution-lag-on-clicks-application-switching-and-general
I'm wondering if there's a way to see which processes hang the most and at what time. For instance, if I click on "New Tab" in Chrome, and it takes 7 seconds for it to open with 3 rainbow wheels appearing during that time, I would like to see an output like this:
CPU1 : Chrome Helper: eventRegister 0.3s --- CPU2 : Chrome Helper: eventTrigger 1.4s CPU2 : kernel_task: <<unknown>> 4s
I'm making stuff up, but basically some kind of debugger which shows the chain of execution and the time it took for each process (am I even using the right terminology?) to execute.
Right now, I have 5 second lags on simple toolbar menu openings, things are becoming unbearable. Disk diagnostics are all good, CPU is constantly under 10% and while RAM is pretty full (I have no apps I can turn off, IntelliJ and Chrome take up 4 GB by themselves already, let alone the rest) I still don't think the lag should be this bad. I would really like to get to the bottom of it, and having a debugger of this kind would help, if there is such a thing.