6 ms·
I don't want to sound negative and I certainly don't want to start a war here. I also really appreciate what Mozilla is doing and I am an otherwise happy user o
by annnnd 12y ago
I don't want to sound negative and I certainly don't want to start a war here. I also really appreciate what Mozilla is doing and I am an otherwise happy user of FF on both desktop and mobile.
That said, FF memory usage (not just pdf.js) is sometimes just insane. Granted, I only have 2GB on this Linux, but FF invariably eats most of it (with just 10-20 tabs) if left running for long periods. Interestingly enough, once I restart FF and reopen the same tabs, memory usage is far lower. Memory leak? Inefficient caching? Who knows...
Every now and then there is a version of FF that claims to be using less memory, but in my experience the differences have been negligible. So as far I am concerned memory friendly FF is something like fast Java... I am still waiting to meet one of these beasts in the wild. :)
- Gracana 12y agoIs firefox actually using memory in such a way that other programs can't use it, or is it simply making efficient use of memory but caching everything it can?
- annnnd 12y agoVM starts swapping so much that it is not usable anymore.
- Gracana 12y agoAh, okay. By the way, I was just fiddling around and found "about:memory", which contains a lot of interesting information about memory usage and a couple tools for cleaning up memory. Might be interesting to look at when the browser starts bogging down your system.
- annnnd 12y ago"about:memory" is probably great, but it is too detailed for someone who is not familiar with FF internal architecture. The way I see it it is mainly useful for FF developers. I like "about:addons-memory" (available if you install https://addons.mozilla.org/en-US/firefox/addon/about-addons-memory/ https://addons.mozilla.org/en-US/firefox/addon/about-addons-...).
- Ygg2 12y agoYou can just use the latest Nightly or Aurora to see how fast these things are compared to yours. I had a same problem, Firefox being slow and clunky so I switched to Nightly and it did really increase the speed. I think Firefox is getting faster but fact is that users also acclimate to new speed and expect it to be faster. EDIT: Right now with about 10 tabs open FF is eating around 580 MB of RAM.
- agumonkey 12y agoI second other people. A while back FF ate ram, but nnethercote and other mozillians have constantly chased sources of memory waste and change memory reclaim heuristics to the point where, to my own surprise, Chrome is now the most memory demanding browser (on my usage, lots of tabs).
- lucian1900 12y agoIndeed, tabs have much higher overhead in Chrome than Firefox. Firefox is possibly the most memory efficient browser out there nowadays. It's just that all browsers eat tons of memory, out of necessity.
- nnethercote 12y agoSorry to hear you're having problems. We need more data to take any kind of action. Are there particular sites that cause problems? Do you have any extensions installed? Even better: can you visit about:memory and use the "Measure and save..." button to get a snapshot of memory usage when it gets high? You can then either email it to me or (preferably) file a bug at bugzilla.mozilla.org and CC me. Bugzilla can be intimidating, but don't worry too much about getting every field right. Just make sure the description is clear. If all that is too hard (hopefully not!), you could try just resetting Firefox: https://support.mozilla.org/en-US/kb/reset-firefox-easily-fix-most-problems https://support.mozilla.org/en-US/kb/reset-firefox-easily-fi.... That's not a guaranteed fix, but it does help in a lot of cases.
- annnnd 12y agoThanks for taking your time to answer, will try to provide as much info as possible. I didn't notice any particular pages which would cause problems, but OTOH there must be a pattern to the pages I visit. I am using FireBug, Abduction, Add to search bar, Greasemonkey (disabling now - didn't know I had it enabled), NoScript and Pencil. Since this happens during normal course of work I would rather send memory usage patterns privately if that's OK with you. The challenge will be to catch FF when the machine hasn't started swapping yet (by then I can count myself lucky if I can still issue killall firefox). Will try to send you "measure and save" output as soon as possible. Thanks!
- nnethercote 12y agoGreasemonkey scripts often cause bad behaviour, though it of course depends on the particular scripts enabled. Firebug can also slow things down a lot, even if it's not enabled. (Apparently Firebug 2.0 is better in this regard.) Selectively disabling extensions isn't the most fun game in the world, but it's often effective in working out if one is causing problems. And private email for the about:memory data is fine. For my email address, take my HN username and append @mozilla.com.
- keeperofdakeys 12y agoMost browsers use this amount of memory. Between JITs, lots of overlapping images, and dynamic content, webpages do actually take a lot of memory to display. In "about:memory", thee is a "Minimize Memory" option, which can work quite well. Personally I have about 70 tabs open, with 1.6GB of memory. This is quite good compared to other browsers I've used.
- nnethercote 12y agoThanks for your realism and understanding! It's nice to hear something other than complaints every once in a while. The things you mentioned all contribute, but most of all, people greatly underestimate the amount of memory required to run JavaScript code. Not so much the JITs, which don't actually use that much, but just all the objects and arrays and strings and closures. Like all high-level, dynamically-typed, garbage collected languages, it uses a fair amount of memory. And the amount of JS code running on many sites is enormous. But people always ask "why is the browser using so much memory", not "why is this site using so much memory". Maybe because per-site memory measurements aren't prominent enough.
- annnnd 12y agoSorry if it sounded like I am complaining, the fact that I still use FF even though it cripples my VM from time to time shows that I am a fan. ;) It is a bit annoying though. > But people always ask "why is the browser using so much memory", not "why is this site using so much memory". Maybe because per-site memory measurements aren't prominent enough. Do you mean to say these measurements exist? I couldn't find them in about:memory (per-site, that is). That would be an awesome feature! I could easily kill the tabs which are eating up my RAM if only I knew which ones were doing it. Better yet, I could see if I am being reckless with memory in my own webapps. The issue I am having is not that browser uses too much RAM. The issue is that I (as a user) am not aware of high memory usage until it is too late. Even worse, I have no clue what caused this state and have no option to learn from previous "mistakes" (if some site is using too much RAM, I could avoid it or close it when not needed anymore). So yes, per-site (per-tab?) memory usage indicators would solve my issue completely. Thanks again for taking your time to answer, and keep up the good work! You have a great product there.
- quasque 12y agoI also have this problem, but on a Windows laptop with 2GB. However, Firefox has recently been crashing several times per day, which sorted out the long-running memory problem but rather inconveniences usage. It's a shame because I really do prefer it to the other browsers, for a variety of reasons.
- nnethercote 12y agoAs I said to the parent: please report your problems. Please include about:memory data. Vague complaints in online forums don't help us fix things.
- acdha 12y agoUninstall your extensions, particularly Ad Block Plus, and see if the problem recurs: https://blog.mozilla.org/nnethercote/2014/05/14/adblock-pluss-effect-on-firefoxs-memory-usage/ https://blog.mozilla.org/nnethercote/2014/05/14/adblock-plus...
- masklinn 12y agoOr just create and try a brand new profile for some time.
- Maskawanian 12y agoHonestly, Mozilla should put together an official version of this plugin, since this feature is absolutely essential to browsers nowadays.
- acdha 12y agoI don't use it at all and rarely notice a problem. Disabling Flash solves the performance / stability issues and I simply don't visit ad infested sites. Ad blockers are a losing game, as demonstrated by the rise of increasingly spammy content, and the only way to change that is stop supporting sites which don't respect you.
- com2kid 12y agoAt which point, I have no reason to be using FF! FF's plugin system is one of its huge advantages. With IE11 at a "good enough" state now, if I'm not installing ABP I'm not going to bother switching away from IE on my machines!
- zz1 12y agoKeep in mind that Adblock Edge is (at least from my point of view) better than ABP
- acdha 12y agoI'm not saying uninstall forever, simply to do so before making claims about Firefox's performance, stability, memory usage, etc. – basic debugging 101 stuff about removing variables. That said, extensions are at the bottom of my list of reasons to use Firefox: support for the latest web standards, performance, security, text rendering quality, usability of the core UI, quality of the developer tools, etc.