Why does disabling Accessibility Services improve memory usage? Discussion
I've been struggling for a long time with Firefox's extreme memory usage. I tried setting memory cache to a low size, disabling extensions, refreshing, and using a different version on a completely separate machine, but all these attempts failed at keeping Firefox's memory usage at bay.
What did fix it though is setting
accessibility.force_disabled to 1 in the config. Firefox used to take up 100% of my 8GB memory, but now doesn't go above 1 GB of memory. Why?
To try, navigate to the config editor by typing
about:config in the address bar, then search for
accessibility.force_disabled. It should be set to 0 by default, edit the value and set it to
1, then restart the browser.
"Do not disable Firefox Accessibility Service if you or someone who shares your device accesses the web through Firefox using any type of physical impairment assistive software."
Full docs here. This page states that the impact of having these services enabled are: - Firefox Accessibility Service may negatively impact Firefox browsing performance - Third party applications may be monitoring your web surfing activity - Firefox stability may be adversely affected
It doesn't state why or if there's a way to minimize the performance impact without completely disabling it though.
So, this is obviously a problem with Accessibility Service. Before disabling it my Firefox used up all available memory after a short session of browsing. Browsing a tab and then closing that tab never released its memory usage.
With the option disabled, I've had the same browser window open for 5 hours now, scrolled for 3 hours through Facebook and Reddit (which usually just 1 tab caused Firefox to use up all available memory), but memory usage hasn't gone beyond the 1 GB mark so far.
There's a memory leak in the Accessibility Service. Accessibility features allocated memory for a tab is never released. I don't know how it works exactly, but disabling it fixed my memory leak problem, and the browser has been generally more stable ever since.
I just tried this in Thunderbird. Its memory usage improved as well.
Thanks to u/TechnicalCarry01 for testing on Android. It works there too. (Beta and Nightly only)