Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slow But Sustained CPU Drain #1388

Closed
rdsubhas opened this issue Feb 16, 2016 · 1 comment
Closed

Slow But Sustained CPU Drain #1388

rdsubhas opened this issue Feb 16, 2016 · 1 comment

Comments

@rdsubhas
Copy link

Hi, firstly thanks so much for this wonderful extension.

I'm observing a slow but consistent CPU drain (0.3% CPU usage), irrespective of any tab is active or not. I'm not sure if this is normal, but 0.3% over a long period of time (I tend to leave Chrome running) seems to consume a lot of energy. Interestingly, uMatrix doesn't have this problem.

So is this an issue, or is there any way the extension can go to complete sleep (0% cpu) when there is nothing active?

With no tabs active:

screen shot 2016-02-16 at 12 35 37 pm

With tabs settled:

screen shot 2016-02-16 at 12 33 33 pm

More details:
Chrome 48.0.2564.109 (64-bit), OSX 10.11.2, uBlock Origin 1.5.6

@gorhill
Copy link
Owner

gorhill commented Feb 16, 2016

Here is a 2-minute video of uBO's CPU usage while the browser is left idle:
https://a.pomf.cat/kblydv.webm

Following this, I opened uBO's dev console, and clicked "Pause script execution" in the Sources pane: the execution was not paused when the browser was left on idle, despite the CPU value sometimes showing "1". This means that whatever is causing CPU to show non-zero value while on idle, it's not uBO's code executing, it's the browser's code.

There is no actual uBO's code being constantly and pointlessly being executed. Also, for such report, a video showing the CPU figure over time is much better than a still picture.

@gorhill gorhill closed this as completed Feb 16, 2016
gorhill pushed a commit that referenced this issue Sep 26, 2016
this fixes overlooked code change in 1d3205e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants