Closed Bug 1169488 Opened 9 years ago Closed 8 years ago

Serious Memory Bloat if left running for several days with a number of tabs open

Categories

(Toolkit :: about:memory, defect)

38 Branch
x86_64
Windows 7
defect
Not set
normal

Tracking

()

RESOLVED INCOMPLETE

People

(Reporter: Graeme, Unassigned, NeedInfo)

Details

(Whiteboard: [MemShrink])

User Agent: Mozilla/5.0 (Windows NT 6.1; rv:38.0) Gecko/20100101 Firefox/38.0
Build ID: 20150513174244

Steps to reproduce:

Left Firefox running for several hours / days with a number (more than 20 tabs) open.  (Running 38.0.1 but had same problem with version 37.)  Environment is Microsoft manilla Windows 7 Professional 64bit on a Dell with 4GB RAM.

I tend to leave a number of tabs open, so that I can go back to them in a few days (or weeks) when I have more time available.


Actual results:

When Firefox first opens (restoring previous session) Windows Task Manager reports its "Memory (Private Working Set)" as 165MB.  I left it running overnight and it is now up to 800MB.  Yesterday I had launched a second application window of Firefox and opened about 15 - 20 more temporary pages.  When I closed all of these page tabs just now, and closed that application window, there was no change in the memory that Task Manager reported (still 800MB).


Expected results:

The memory usage should not bloat like that, and the Firefox process should release memory when a second Firefox application is closed.

We are software developers ourselves (based in Auckland, New Zealand), so you are more than welcome to ask for more technical cooperation if you need it.  My phone number is +64 9 262 2020 Ext 5  or  Skype "adminsoft.com".
When you close tabs/windows and memory is not released, please check about:memory and see if there's ghost-windows. There is a bug about ghost-windows open: bug 1158648
Thanks Guilherme,  I have found (after a Google search) how to access the "about:memory" page.  "Measure" only reports 6 bytes being used by two ghost-windows.  So it seems that ghost-windows are not the cause of the memory leak.

I currently have about 20 page tabs "permanently" retained (i.e. open) for me to go back to read (and follow up) when I have the time to do so.  In the course of trying to research this issue further (and follow a few tangents in the process) I opened (and left open) a further 25 pages.

I have run "Measure and Save" several times - including before ending the Firefox.exe process (460MB) and after re-launching the Firefox application (only 200MB reported by Windows Task Manager).  I will leave Firefox open for the rest of day and overnight, and run another "Measure and Save" once it has bloated significantly.  I can then upload (or email) these files if someone wants to look at them.

Just a thought:  Does Firefox have a timer, and automatically run the "Minimize memory usage" facility every hour or so, say?

Regards, Graeme
OS: Unspecified → Windows 7
Hardware: Unspecified → x86_64
I left FireFox open for several days, and Windows Task Scheduler reported that Firefox memory usage had bloated to 770MB (having been only 200MB after restarting it with previous session restored on 30 May).

Using about:memory "Load and difference" facility to compare the "Measure and save" files (today v 30 May) reveals that the issue seems to be within the "js-main-runtime" (337 MB increase) and "js-main-runtime-gc-heap-committed" (221 MB increase).  I can upload (or email) these "json.gz" files if someone wants to look at them.

Interestingly, about:memory "Minimize memory usage" only reduced the memory usage reported by Task Scheduler down to 700MB.  However, after closing Firefox (using End Task so all open pages retained) and using "Restore" after re-starting Firefox, Task Scheduler reports it using 215 MB of memory).

Regards, Graeme
Whiteboard: Memory leak seems to be within "js-main-runtime"
Component: Untriaged → Tabbed Browser
Component: Tabbed Browser → about:memory
Product: Firefox → Toolkit
Graeme, is this still a problem? If so, can you please upload about:memory measurements? We need more data to make any useful diagnosis.

https://developer.mozilla.org/en-US/docs/Mozilla/Performance/about:memory has documentation, especially the "How to generate memory reports". If you can take two sets of reports, one early and one later when the memory usage is higher, that would be helpful. Thank you.
Flags: needinfo?(Graeme)
Whiteboard: Memory leak seems to be within "js-main-runtime" → [MemShrink]
Closing due to lack of response from reporter. Please reopen if you have more data, as per comment 4.
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.