Dave Hunt wrote this week about some endurance tests comparing Firefox 4, 5, 6, 7, and 8, which show how Firefox’s memory usage is improving. Pay most attention to the ‘resident’ numbers for Firefox 6, 7 and 8, which indicate how much physical memory is being used. The ‘explicit’ numbers show a big drop between 6 and 7, and then a rise between 7 and 8, but they are suspect, so don’t panic yet.
about:memory improved again this week. I added a reporter for each compartment’s property table, and two reporters
js-compartments-user which count how many compartments are present. These latter two will be added to telemetry soon.
I also added a reporter that computes the fraction of the JS heap that is unused, called
js-gc-heap-unused-fraction. The results are surprising — numbers like 30% and 50% are common. (Some preliminary JS heap visualization helps explain why.) There are some suggestions for short-term improvements to mitigate this (e.g. smaller GC chunks). However, I suspect that to fix it properly will require a compacting garbage collector — the current mark and sweep algorithm unavoidably leaves lots of holes all over the heap each time it runs. But I could be wrong! GCs have a large design space and there may be other solutions. A non-compacting generational GC would help in its own way too — fewer objects would reach the general heap and so each full heap collection would likely collect less garbage, and thus leave fewer holes.
Here’s this week’s bug count:
- P1: 30 (+4)
- P2: 48 (-1)
- P3: 33 (+0)
- Unprioritized: 8 (+2)
It’s nice to see the P2 count go down! Note that bugs remain unprioritized for two reasons. First, we don’t always get through all the unprioritized bugs in the MemShrink meeting. Second, sometimes we ask for more investigation or data before assigning a priority.
On the topic of bugs, I closed the meta-bugs for tracking leaks against Firefox releases, and the one for tracking non-leak memory use reductions, as I mooted last week. I kept open the one for improving memory-related tools because multiple people though it was useful.