Open rolandog opened 2 years ago
I reported the behavior upstream (Possible sleeping tab wake-up leading to high CPU and memory usage when sorting many (many) tabs). I'm still not sure what is the cause.
I'm not an expert in reading this kind of report but having a performance profile recording of this issue could probably give us more information of what's going on. You can record a profile with https://profiler.firefox.com/ and share it here.
If you need help, you can join #profiler:mozilla.org and/or #perf:mozilla on our Mozilla Matrix Server. See https://wiki.mozilla.org/Matrix to a quick how-to connect to Matrix.
Actual behavior
So, I had a couple of very busy months that lead me to having around (don't judge me... too harshly) 2000 tabs open. I had been kicking the can down the road of properly sorting and organizing tabs, so I decided to "Sort Tabs by Container"... and this ended up nearly crashing my laptop, and hogging a lot of CPU and memory, and even using swap.
I decided to de-duplicate some tabs with Foxytab, and then tried sorting by URL (I know this is out of scope), but that did end up leaving the laptop in an unresponsive state, and I had to physically reboot.
After sending to OneTab, the total tab count was 2003: (1994 tabs, plus 9 pinned tabs).
I think I will report the bug in three places: here (the multi-account-containers add-on repository), in the FoxyTab repository, and in Firefox's Bugzilla, since I think that using so much memory for sorting tabs shouldn't be necessary.
Expected behavior
Sorting a lot of tabs should not require so much CPU and Memory (perhaps the tabs were being brought out of sleep just to be able to be re-ordered?)
Steps to reproduce
browser.tabs.unloadOnLowMemory
set totrue
Notes
This may be related to #1869, and to #572.
Here a screenshot of
htop
showing the memory usage of Firefox while sorting by container:And here's a screenshot of
htop
of the laptop's baseline after closing Firefox (I can't remember if I interrupted the sorting or left it to finish):