Ubuntu – How to narrow down what is taking 100% CPU on alternating cores

cpugoogle-chrome

Whilst watching video one core will spike to 100% for a few moments drop off and then another core will spike to 100%.

30 second htop .gif

one cpu 100%.gif

30 second conky .gif

one cpu conky 100%.gif

Other points:

  • CPU MHz running over 3000 Mhz (3 GHz) when it is normally around 1000 MHz
  • Temperature about 20 degrees Celsius above normal.

Narrowing it down

While writing this question I accidentally closed the chrome tab with the video on external monitor. CPU frequencies and load dropped to normal. I've noticed before how apt-get will spike a single CPU to 100% but this problem is nothing like that.

The process causing abnormal behaviour is chrome but what steps can be taken to narrow it down? ie Can a certain sub-process be identified within video codec-land (whatever you call it) and targeted for bug reporting?

Chrome Version

Version 63.0.3239.132 (Official Build) (64-bit)

Best Answer

Using htop you can

  1. sort by CPU usage with P
  2. follow the process with F
  3. Switch to Tree view with t / F5