Closed jody-frankowski closed 1 week ago
See #308 for a simple solution for PortCapture
. I simply removed it as I have not found it to be currently used.
Interesting find. Removing PortCapture doesn't seem to solve the leak for me. As for why I even have PortCapture in first place. I'm not 100% sure 😕, but I remember it had something to do with port disconnect event not triggering properly without keeping a reference. I will sidestep this issue by working on the Manifest V3 update. Background pages are no longer supported in Manifest V3, so the issue should resolve indirectly.
As there seems to be at least another one (based on my research), if you ping this post when the manifest V3 lands on git, I'll give it a try if I have the time :)
+1 This extension definitely has memory leaks as it can take up to several gigabytes of memory until I restart it or the browser (Firefox). On Chromium however I didn't encounter any memory leaks.
I just did a diff in about:memory for before and after disabling this extension, and the result is -1061 MiB memory usage for the extension process.
Apologies for the long delay. Just uploaded the Manifest V3 version of Global Speed. Hopefully the issue is resolved with that. Still not sure what caused the memory leak. I'm surprised not a lot of people complained. Maybe it was only affecting certain people.
The update should get approved soon, maybe tomorrow.
I don't have the memory issue with the new version.
It looks like there are multiple (at least two, I would say) memory leaks in the extension. I stumbled upon them when I did a
about:memory
report. I found that the extension held in memory lots of copies of strings, and the main culprits being base64 encoded favicons of visited sites belonging totabs.Tab
objects (I think). The session was long-running, with lots of tabs opened and closed since its beginning. I have only been able to pinpoint thePortCapture
class as one of the sources. But there seems to be another one, because I have tried to remove the class entirely, and I still saw the same allocations.How to reproduce:
about:memory
reportabout:memory
reportdata:image
explicit/window-objects/top(moz-...)/js-zones(0x...)/string(length=...)
window.portCapture.ports
contains some information of a closed tab