View Full Version : Firefox Memory Leak?
pop pop
07-03-2009, 11:24 PM
I thought the memory leak was supposed to be fixed. My wife leaves Firefox open and it slowly consumes all RAM and virtual memory to the point where her PC shuts down (I know, bad habit but she's stubborn).
On my new build, I've watched my memory usage go from about a steady 12 percent to a currently steady 26 percent. This has been over about three days of uptime. Although I shut Firefox down when I'm done, I'm guessing the memory it uses is not released until a reboot. ANyone else see similar? Take a look at the graphic below. Firefox is THE biggest memory using process on my system. The biggest. Nothing else comes close.
http://img30.imageshack.us/img30/430/firefoxmemoryleak.gif
PrntRhd
07-04-2009, 12:27 AM
What extensions are you running?
I am running v3.5 and am seeing 62,842K
And yes it is a little pig-ish.
pop pop
07-04-2009, 12:39 AM
Only these and that's not as much as I used to. The Forecast Bar Enhanced may account for some of it, but my wife runs no add ons and the memory creep/leak is just as bad. I gues, what with RAM prices and amounts these days, a hundred+ Mb isn't insane...but the leak and lack of memory release after closing is.
http://img398.imageshack.us/img398/848/firefoxaddons.gif
pop pop
07-04-2009, 03:35 AM
This isn't a leak, it's a flood. The increase from a few hours ago is not insignificant. A 28 percent increase in virtual and a 133 percent increase in peak. I was watching video on Hulu an hour ago. That probably is the spike in peak.
Edit: Just noticed I can't spell at almost 3 am and I can't correct it. :eek: :o
http://img182.imageshack.us/img182/2019/firefoxmemoryleakjuly04.gif
PrntRhd
07-05-2009, 06:28 PM
Mozilla is expecting to release a Firefox revision fixing some of the identified 55 bugs, including slow starting in 30 days.
Some sources estimated it would have delayed release of the browser by 6 months if all 55 had been fixed first.
Ironically some slow starting issues on Firefox/Windows may be helped by deleting the IE temporary internet files?
pop pop
07-05-2009, 06:37 PM
I haven't gone to 3.5 yet...I like my add ons.
deleting the IE temporary internet files?
Start up is actually fine. I run CCleaner often and get rid of all the garbage. :)
jlreich
07-05-2009, 08:31 PM
I haven't gone to 3.5 yet...I like my add ons.
Start up is actually fine. I run CCleaner often and get rid of all the garbage. :)
Same here on both accounts. ;)
Sylvander
07-06-2009, 05:02 AM
How Puppy works. (http://www.puppylinux.com/development/howpuppyworks.html)
1. I wonder whether Windows [which keeps its operating methods secret] works anything like Puppy Linux [which is open about how it works].
I'm no expert, but here's what I think I understand:
(a) Puppy runs in a RAMdrive that's held totally in RAM [normally, and if possible], and might overflow into a Linux swap partition if too much for RAM.
(b) The persistent storage [of config changes and new package installations] is held in say a read-only "pup_save" file [depends upon the type of install] that isn't loaded into the RAMdrive.
(c) The RAMdrive holds only the "working" files = new and/or changed files.
As you work, files might be added to the file system held in the RAMdrive [in RAM+swap], thereby increasing the space occupied.
(d) This might result in space running short, with a warning being displayed.
e) In such circumstances, the normal solution is to reboot, at which time the contents of the RAMdrive are SAVED to the [normally read-only during a session] "pup_save" file, and once back into Puppy the RAMdrive is back to a small size with little "working" files.
(f) With a [normal] Puppy HDD installation, the files are constantly being saved to the HDD, so this situation never normally appears.
(2) So I wonder what Windows does about saving "new & changed" files back to the HDD?
Paul Komski
07-06-2009, 06:11 AM
Saving new and changed files to disk has nothing to do with "memory leaks". Even when a system runs from a RAMdrive portions of available memory (RAM and/or VirtualMemory/SwapFile/PageFile) are reserved/gobbled-up when applications are running; they need this space to allocate their own resources within while they are running. For example a section, routine or function might want to load an array into memory so that all the array variables can be stored in the array and then those elements be quickly read from the array when doing all sorts of calculations. Such arrays would need to remain occupying that space until no longer needed - at which point the function or routine should release that memory back into the pool. If not so released there is a so called "memory leak"; a leak because that memory remains unavailable to anything having been "leaked away".
With good programming such areas of memory are released either when the routines themselves end or when an application window/form closes or when the program itself totally shuts down. However it is very easy to miss these when programming and so a memory leak can be one sort of "bug" that needs detecting (not always at all easy) and eliminating.
At some point in time Firefox's Windows Software became very buggy, slowed-down and so on. Unfortunate because it was first class for a long time and will, I am sure, return to that status. Of course if closing FF doesn't release the memory then the whole system suffers. Just to restate that this has nothing to do with Windows (or its secret source code) per se; it is an application development problem - nothing more.
As for saving changed data to disk. This depends, once again, on the application itself - rather than the operating system. Most database-type elements of programs get updated as soon as the change is made. An OE dbx file is updated as each email is downloaded for example and a MSAccess mdb file is updated whenever a field entry is changed. Other "more static" files such as txt or pdf or doc or xls files can be auto-updated on occasions by the programs using them but it is more normal to wait until the user invokes a save (eg by CTRL+S) or until the document is closed and the user prompted to save the changes or not. Until such documents are "updated" the changes are only held in memory or in a temporary file; temporary files which enable the ability to undo previous changes.
PrntRhd
07-06-2009, 11:02 PM
Slowness can also occur on systems with both Firefox and IE8. Seems they share some DLLs relating to Javascript.
http://forums.mozillazine.org/viewtopic.php?f=38&t=1204385&start=0&st=0&sk=t&sd=a
Paul Komski
07-07-2009, 02:11 AM
Seems they share some DLLs relating to Javascript.Would be sceptical about the JS relationship and suspect that the update to .NET framework, mentioned towards the end of the thread, was just as or more likely to be the culprit than the upgrade to IE8. From memory I fairly recently had problems on a new laptop running Vista after the .NET framework update and had to reverse it.
PrntRhd
07-12-2009, 10:48 PM
I came across this on another site, Firefox 3's SQLite Databases can be optimized for Windows, Linux, and Mac:
http://webupd8.blogspot.com/2009/07/increase-firefox-3-perormance-by.html
pop pop
07-12-2009, 11:34 PM
The issue is as Paul described it. The memory is "grabbed" and used as needed, but not released by the application. It's a classic memory leak and, for FF, it has been around for a long time.
Memory management, and memory leaks, are an art and a pain to resolve, respectively. I guess the big problem is determining what thread or whatever holds the memory and is not cleaning up after itself.
With memory being a cheap commodity these days, I guess there are higher priorities.
I have updated to FF 3.5 and I have to say the memory foot print is smaller. Time will tell.
PrntRhd
07-13-2009, 01:56 AM
Pop Pop, I agree, the last link I posted is to make the application open more quickly.
vBulletin v3.6.1, Copyright ©2000-2009, Jelsoft Enterprises Ltd.