gh-dash icon indicating copy to clipboard operation
gh-dash copied to clipboard

[BUG]: unexpected amount of CPU usage

Open Ax51 opened this issue 1 year ago • 1 comments

Describe the bug A clear and concise description of what the bug is.

Just running the extension consumes about a quarter of the CPU resources. This behaviour is unexpected

To Reproduce Steps to reproduce the behavior:

  1. Open Activity Monitor app
  2. Go to the terminal and open extension
  3. Return to Activity Monitor app and check for gh dash process name

Expected behavior A clear and concise description of what you expected to happen.

Consume less cpu %. For example running kitty instance consumes just about 0.6% of cpu. actively running eslint_d instance consumes not more than 15%.

Screenshots If applicable, add screenshots to help explain your problem.

image

Desktop (please complete the following information):

  • OS: [e.g. Mac] macOS Sonoma 14.5
  • Chip: Apple M2 pro
  • Memory: 16 GB

Update:

Used extension ver.: 4.3.0 image

Ax51 avatar Jul 05 '24 09:07 Ax51

Doesn't behave this way for me, but then I'm on x64, and you're running on an ARM architecture, not to mention Linux vs. macOS...

I have an ARM board I'm planning to get up and running in the next few days, so I can check there, see if anything is different.

Better would be if you could generate a CPU profile. The changes in this branch are all you actually need to generate one: https://github.com/Omnikron13/gh-dash/tree/cpu-profile

go tool pprof cpu.profile after you close out the profiling build of gh-dash will open up the interactive tool google ship for probing the profile.

The top10 command might shed some light on what is actually using CPU cycles, or the web command should generate a nice visualisation of where they're all going in your browser.

Omnikron13 avatar Jul 09 '24 19:07 Omnikron13

Sorry for the late reply. Seems that issue is solved with some update because since then I couldn't caught such behaviour. As for this moment gh-dash doesn't consume any abnormal amount of resources. Thanks for the updates and for the plugin!

Current consumption rates:

Image

Ax51 avatar May 15 '25 10:05 Ax51