unloaded pinned tabs still spawn a process when pref browser.sessionstore.restore_pinned_tabs_on_demand is true
Categories
(Firefox :: Session Restore, defect, P3)
Tracking
()
People
(Reporter: promarbler14, Unassigned)
References
(Depends on 1 open bug)
Details
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/117.0
Steps to reproduce:
- Have session restore enabled
- Have on-demand loading set for tabs (default?) and pinned tabs (have pref browser.sessionstore.restore_pinned_tabs_on_demand = true)
- Optionally, have pref browser.tabs.tooltipsShowPidAndActiveness set to true and the "Auto Tab Discard" extension installed.
Open some tabs, pin some of those tabs, then quit and reopen Firefox. Hover over the tab for a pid, or check about:processes.
Actual results:
When Firefox is started, neither pinned tabs nor unpinned tabs will be loaded after the windows are restored. However, when examining about:processes (and formerly about:performance), the pinned tabs would still have a process (OS task with a pid) created for them. Each tab will be idle. Unpinned tabs would have no process created. Multiple processes would be created for a pinned site (seemingly per-domain) with only one (discarded) tab assigned to it (in this case, about:processes reports it consumes 13-15 MB per redundant process). With many pinned tabs present, this created a lot of wasted processes and memory on the system. As an example from my case, while I only have one Twitter tab open in its container, I have four unloaded pinned Twitter tabs as well. This created four processes, three of which are completely redundant and have consumed zero CPU time.
Note that after startup, "unloaded" and loaded pinned tabs can still be manually discarded (via an extension, from the tab context menu) to remove the process from the tab. As far as I know, there is no way to do this in batch.
Expected results:
Processes should just be spawned only for the tabs that are focused in each window. Pinned tabs, with the aforementioned on-demand preference set, should not differ from unpinned tabs in this regard. Processes should also not exist solely for the purpose of storing a single unloaded (pinned) tab.
Comment 1•2 years ago
|
||
The Bugbug bot thinks this bug should belong to the 'Firefox::Session Restore' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
Comment 2•2 years ago
|
||
I can confirm the reporter's observations on Windows and Linux systems.
Steps confirmed:
- Session Restore,
- pref browser.sessionstore.restore_pinned_tabs_on_demand = true (false by default in nightly)
- pref browser.tabs.tooltipsShowPidAndActiveness = true (default in nightly)
- Install the Auto Tab Discard extension
- Load Twitter/Facebook and log in
- Load at least another 3 subpages of the same domain.
- Pin 2 tabs.
- Load about:processes page
- Close and reopen browser.
- Observe the processes
Actual: There are 2 processes for the 2 pinned tabs, but no processes for the unpinned tabs.
Expected: The reporter expects there are no active processes for pinned tabs in this situation.
I am not familiar with these prefs and settings and I can't determine if this is a valid or invalid behavior, but I will confirm this report and let developers have a better opinion on it. The same behavior can be observed even in ESR 102.15.1esr.
Thank you for your contribution!
Comment 3•2 years ago
|
||
(In reply to Daniel Bodea [:danibodea] from comment #2)
I can confirm the reporter's observations on Windows and Linux systems.
Steps confirmed:
- Session Restore,
- pref browser.sessionstore.restore_pinned_tabs_on_demand = true (false by default in nightly)
- pref browser.tabs.tooltipsShowPidAndActiveness = true (default in nightly)
- Install the Auto Tab Discard extension
Is this extension necessary to reproduce the issue :danibodea? In comment #0 its indicated as optional.
| Reporter | ||
Comment 4•2 years ago
|
||
Note that after startup, "unloaded" and loaded pinned tabs can still be manually discarded (via an extension, from the tab context menu) to remove the process from the tab.
The extension is only used to provide a way to discard a tab after startup, to illustrate the point that pinned tabs can still be discarded manually. Likewise, the pref browser.tabs.tooltipsShowPidAndActiveness is used to more easily tell if a process for the tab exists. For the issue itself (pids exist for unloaded pinned tabs on startup), they should be completely optional and checking about:processes should be sufficient.
Comment 5•2 years ago
|
||
I confirm that the issue also reproduces without installing the addon.
Comment 6•2 years ago
|
||
The severity field is not set for this bug.
:dao, could you have a look please?
For more information, please visit BugBot documentation.
Updated•2 years ago
|
I can reliably reproduce this bug in the latest stable release of Firefox v147.0.3 (64-bit)
Firefox continues to spawn processes for all pinned tabs on browser start even when
browser.sessionstore.restore_pinned_tabs_on_demand is set to true
Description
•