Open Germano0 opened 2 years ago
Do you have a lot of tabs open?
I can confirm I have the same issue, and yes, I do have a lot of tabs open.
Select the option "Process only active tabs" under General options and see if that helps.
I selected Process only active tabs
, restarted Firefox, but the CPU usage is still high. Yes I have many tabs, but for example UBlock Origin is not suffering from the high amount of opened tabs
Please export your options to a file and email it to leechblockng@proginosko.com so I can investigate further.
For the record, I selected Process only active tabs and it seems to have fixed the issue. I still wonder though, where the issue was coming from in the first place. I thought LeechBlock was only in operation when a new page is being loaded, is that not so?
No, LB regularly checks tabs in case the blocking conditions have been met since the page originally loaded (e.g., the time limit has been reached, or a page with dynamic content has introduced a keyword that should trigger a block). This is necessary to support the "Immediately block pages on these sites once blocking conditions are met" option.
Fair enough, but if that option is off (as it is in my case), then LB should only activate when a new page is being loaded, shouldn't it?
Sorry, I should have added that LB regularly checks tabs also to keep track of the amount of time spent on sites. That will happen regardless of the "Immediately block" setting. If you've selected "Process only active tabs" you shouldn't have high CPU usage though. Do you have a very long block list?
No, I'm blocking around 20 domains in total. I also don't have any rules set up to block pages after a certain amount of time. I don't have a high CPU usage all the time now (having ticked "Process only active tabs"), but there are still CPU usage spikes from LB every now and then.
Even if LB has to regularly check a large number of tabs for time spent, I don't see how that should make it use a lot of CPU, that is not a complicated operation, is it? It's not like I have millions of tabs.
Sorry, I should have added that LB regularly checks tabs also to keep track of the amount of time spent on sites. That will happen regardless of the "Immediately block" setting. If you've selected "Process only active tabs" you shouldn't have high CPU usage though. Do you have a very long block list?
Why does LB keep track of the amount of time when I have not set time limits? Why does LB keep track of the amount of time on all (active) tabs instead of just the focused one?
Why does LB keep track of the amount of time when I have not set time limits?
(1) For the Statistics page. (2) In case a time limit is added on the fly.
Keeping track of the time is not itself CPU intensive. Even without a time limit for a block set, the processing would be much the same.
Why does LB keep track of the amount of time on all (active) tabs instead of just the focused one?
"Active tab" just means the focused tab in this context.
Keeping track of the time is not itself CPU intensive.
Okay, then why is this extension by far the highest energy impact in the firefox task manager constantly?
In your case, I don't know (yet). You make it sound like this is an issue for all users, but as far as I can tell, it's only an issue for a small number of users. If you want to help, you could do some diagnostics to narrow down the cause. Disable all but one of the block sets (see option to disable under Advanced Options) and see if the CPU impact is still high. Repeat for the other (used) block sets. See if the issue can be traced to one particular block set, and if so, we can take a closer look.
When Firefox 104 is using a lot of CPU and you open
about:performance
, you will often find out that the reason is LeechBlock NG1.5.1