Bug 1036443 - RHEVM: Extremely high memory usage in Firefox
Summary: RHEVM: Extremely high memory usage in Firefox
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: firefox
Version: rawhide
Hardware: All
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Martin Stransky
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1043430
TreeView+ depends on / blocked
 
Reported: 2013-12-02 01:25 UTC by Pieter Demmers
Modified: 2018-12-06 15:31 UTC (History)
13 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-08-25 12:28:55 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
about:memory of Firefox 24.2.0 (firefox-24.2.0-6.el6_5.x86_64) (910.60 KB, application/xhtml+xml)
2014-01-15 18:47 UTC, Pavel Novotny
no flags Details
about:memory of upstream Firefox 26.0 (3.12 MB, application/xhtml+xml)
2014-01-15 18:48 UTC, Pavel Novotny
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 533353 0 None None None Never

Description Pieter Demmers 2013-12-02 01:25:36 UTC
Description of problem:

Prior to upgrading to Fedora 19, I was running Fedora 18 as my corporate desktop PC.  Under Fedora 18, RHEVM (3.2) performed well (i.e. did not frequently freeze for several seconds and was not sluggish).  Since upgrading to Fedora 19, RHEV-M frequently freezes for several seconds at a time and is very sluggish.  

about:memory (output below) shows very high memory usage.  The Fedora 19 box has 20GB RAM.  The about:memory was run with RHEVM on both prod and dev plus three other tabs, although those other tabs should have had very slight requirements.

---
Main Process

WARNING: the following values are negative or unreasonably large.

    explicit/(19 tiny)/heap-unclassified 

This indicates a defect in one or more memory reporters. The invalid values are highlighted.
Explicit Allocations

3,450.33 MB (100.0%) -- explicit
├──3,207.94 MB (92.97%) -- window-objects
│  ├──1,890.20 MB (54.78%) -- top(https://benvup3p.scada.horizonpower.com.au:8443/webadmin/webadmin/WebAdmin.html#vms-permissions, id=23)
│  │  ├──1,866.42 MB (54.09%) -- active
│  │  │  ├──1,750.84 MB (50.74%) -- window(https://benvup3p.scada.horizonpower.com.au:8443/webadmin/webadmin/WebAdmin.html#vms-permissions)
│  │  │  │  ├──1,604.19 MB (46.49%) -- dom
│  │  │  │  │  ├──1,601.55 MB (46.42%) ── orphan-nodes
│  │  │  │  │  └──────2.65 MB (00.08%) ++ (4 tiny)
│  │  │  │  ├────142.09 MB (04.12%) -- js-compartment(https://benvup3p.scada.horizonpower.com.au:8443/webadmin/webadmin/WebAdmin.html)
│  │  │  │  │    ├──120.20 MB (03.48%) -- gc-heap
│  │  │  │  │    │  ├───53.32 MB (01.55%) ++ objects
│  │  │  │  │    │  ├───42.11 MB (01.22%) ── scripts
│  │  │  │  │    │  └───24.76 MB (00.72%) ++ (2 tiny)
│  │  │  │  │    └───21.90 MB (00.63%) ++ (6 tiny)
│  │  │  │  └──────4.56 MB (00.13%) ++ (3 tiny)
│  │  │  ├────115.00 MB (03.33%) -- window(https://benvup3p.scada.horizonpower.com.au:8443/webadmin/webadmin/1460A4D2C6F36D1B7D44BC985B8E2849.cache.html)
│  │  │  │    ├──110.19 MB (03.19%) -- js-compartment(https://benvup3p.scada.horizonpower.com.au:8443/webadmin/webadmin/1460A4D2C6F36D1B7D44BC985B8E2849.cache.html, about:blank)
│  │  │  │    │  ├───78.86 MB (02.29%) -- objects-extra
│  │  │  │    │  │   ├──72.38 MB (02.10%) ── elements/non-asm.js
│  │  │  │    │  │   └───6.47 MB (00.19%) ── slots
│  │  │  │    │  └───31.33 MB (00.91%) ++ (7 tiny)
│  │  │  │    └────4.81 MB (00.14%) ++ (3 tiny)
│  │  │  └──────0.58 MB (00.02%) ++ (2 tiny)
│  │  └─────23.77 MB (00.69%) ++ (2 tiny)
│  ├──1,301.86 MB (37.73%) -- top(https://benvup1d.scadadev.horizonpower.com.au:8443/webadmin/webadmin/WebAdmin.html#vms-network_interfaces, id=17)
│  │  ├──1,280.37 MB (37.11%) -- active
│  │  │  ├──1,153.69 MB (33.44%) -- window(https://benvup1d.scadadev.horizonpower.com.au:8443/webadmin/webadmin/WebAdmin.html#vms-network_interfaces)
│  │  │  │  ├──1,059.63 MB (30.71%) -- dom
│  │  │  │  │  ├──1,057.61 MB (30.65%) ── orphan-nodes
│  │  │  │  │  └──────2.01 MB (00.06%) ++ (4 tiny)
│  │  │  │  ├─────90.10 MB (02.61%) -- js-compartment(https://benvup1d.scadadev.horizonpower.com.au:8443/webadmin/webadmin/WebAdmin.html#vms)
│  │  │  │  │     ├──78.80 MB (02.28%) -- gc-heap
│  │  │  │  │     │  ├──43.68 MB (01.27%) ++ (3 tiny)
│  │  │  │  │     │  └──35.13 MB (01.02%) ++ objects
│  │  │  │  │     └──11.29 MB (00.33%) ++ (5 tiny)
│  │  │  │  └──────3.97 MB (00.11%) ++ (3 tiny)
│  │  │  ├────125.59 MB (03.64%) -- window(https://benvup1d.scadadev.horizonpower.com.au:8443/webadmin/webadmin/E8EB78E8C06F1B5885712783392BD079.cache.html)
│  │  │  │    ├──120.70 MB (03.50%) -- js-compartment(https://benvup1d.scadadev.horizonpower.com.au:8443/webadmin/webadmin/E8EB78E8C06F1B5885712783392BD079.cache.html, about:blank)
│  │  │  │    │  ├───87.88 MB (02.55%) -- objects-extra
│  │  │  │    │  │   ├──80.64 MB (02.34%) ── elements/non-asm.js
│  │  │  │    │  │   └───7.23 MB (00.21%) ── slots
│  │  │  │    │  └───32.82 MB (00.95%) ++ (6 tiny)
│  │  │  │    └────4.90 MB (00.14%) ++ (3 tiny)
│  │  │  └──────1.09 MB (00.03%) ++ (3 tiny)
│  │  └─────21.49 MB (00.62%) ++ js-zone(0x7f78638c4000)
│  └─────15.88 MB (00.46%) ++ (9 tiny)
├────133.95 MB (03.88%) -- js-non-window
│    ├──101.75 MB (02.95%) -- runtime
│    │  ├───87.72 MB (02.54%) ── script-sources
│    │  └───14.03 MB (00.41%) ++ (11 tiny)
│    └───32.20 MB (00.93%) ++ (2 tiny)
├─────59.20 MB (01.72%) -- (19 tiny)
│     ├──24.00 MB (00.70%) ── dom/event-listener-managers-hash
│     ├──17.47 MB (00.51%) ++ storage
│     ├──14.33 MB (00.42%) ++ workers/workers()
│     ├──13.66 MB (00.40%) ++ cycle-collector
│     ├───3.27 MB (00.09%) ++ add-ons
│     ├───2.37 MB (00.07%) ++ startup-cache
│     ├───1.43 MB (00.04%) ++ images
│     ├───1.11 MB (00.03%) ── xpti-working-set
│     ├───1.02 MB (00.03%) ── atom-tables
│     ├───0.69 MB (00.02%) ++ gfx
│     ├───0.41 MB (00.01%) ++ xpcom
│     ├───0.37 MB (00.01%) ++ layout
│     ├───0.30 MB (00.01%) ── preferences
│     ├───0.15 MB (00.00%) ── script-namespace-manager
│     ├───0.06 MB (00.00%) ++ network
│     ├───0.04 MB (00.00%) ── telemetry
│     ├───0.02 MB (00.00%) ── history-links-hashtable
│     ├───0.00 MB (00.00%) ── spell-check
│     └──-21.52 MB (-0.62%) ── heap-unclassified [?!]
└─────49.24 MB (01.43%) ── xpconnect

Other Measurements

19.65 MB (100.0%) -- decommitted
├──19.65 MB (100.0%) ── js-non-window/gc-heap/decommitted-arenas
└───0.00 MB (00.00%) ++ workers/workers()

297 (100.0%) -- js-compartments
├──278 (93.60%) ── system
└───19 (06.40%) ── user

655.66 MB (100.0%) -- js-main-runtime
├──488.65 MB (74.53%) -- compartments
│  ├──265.51 MB (40.49%) -- gc-heap
│  │  ├──134.21 MB (20.47%) -- objects
│  │  │  ├───65.03 MB (09.92%) ── ordinary
│  │  │  ├───57.79 MB (08.81%) ── function
│  │  │  ├────9.83 MB (01.50%) ── dense-array
│  │  │  └────1.56 MB (00.24%) ── cross-compartment-wrapper
│  │  ├───75.92 MB (11.58%) ── scripts
│  │  └───55.38 MB (08.45%) -- shapes
│  │      ├──29.68 MB (04.53%) ── base
│  │      ├──21.92 MB (03.34%) -- tree
│  │      │  ├──14.92 MB (02.28%) ── non-global-parented
│  │      │  └───6.99 MB (01.07%) ── global-parented
│  │      └───3.78 MB (00.58%) ── dict
│  ├──168.56 MB (25.71%) -- objects-extra
│  │  ├──153.14 MB (23.36%) ── elements/non-asm.js
│  │  ├───15.35 MB (02.34%) ── slots
│  │  └────0.06 MB (00.01%) ++ (2 tiny)
│  ├───43.84 MB (06.69%) -- shapes-extra
│  │   ├──33.62 MB (05.13%) ── compartment-tables
│  │   ├───8.38 MB (01.28%) ── tree-tables
│  │   └───1.84 MB (00.28%) ++ (2 tiny)
│  └───10.74 MB (01.64%) ++ (8 tiny)
├──101.75 MB (15.52%) ── runtime
├───57.62 MB (08.79%) -- zones
│   ├──48.19 MB (07.35%) -- gc-heap
│   │  ├──31.52 MB (04.81%) ── unused-gc-things
│   │  └──16.67 MB (02.54%) ++ (5 tiny)
│   └───9.43 MB (01.44%) ++ (4 tiny)
└────7.65 MB (01.17%) ++ gc-heap

321.35 MB (100.0%) -- js-main-runtime-gc-heap-committed
├──287.50 MB (89.47%) -- used
│  ├──277.37 MB (86.31%) ── gc-things
│  ├────5.33 MB (01.66%) ── chunk-admin
│  └────4.80 MB (01.50%) ── arena-admin
└───33.85 MB (10.53%) -- unused
    ├──31.52 MB (09.81%) ── gc-things
    └───2.32 MB (00.72%) ++ (2 tiny)

2,689.49 MB (100.0%) -- window-objects
├──2,674.58 MB (99.45%) -- dom
│  ├──2,659.19 MB (98.87%) ── orphan-nodes
│  └─────15.39 MB (00.57%) ++ (6 tiny)
└─────14.91 MB (00.55%) ++ (3 tiny)

    0.00 MB ── canvas-2d-pixel-bytes
    8.58 MB ── gfx-surface-image
    5.29 MB ── gfx-surface-xlib
    0.00 MB ── gfx-textures
          0 ── ghost-windows
3,120.35 MB ── heap-allocated
3,273.29 MB ── heap-committed
  152.79 MB ── heap-committed-unused
      4.89% ── heap-committed-unused-ratio
    2.36 MB ── heap-dirty
  215.50 MB ── heap-unused
    0.02 MB ── images-content-used-uncompressed
  341.00 MB ── js-gc-heap
    5.59 MB ── js-main-runtime-temporary-peak
        280 ── page-faults-hard
391,586,277 ── page-faults-soft
3,649.60 MB ── resident
3,640.10 MB ── resident-unique
   16.11 MB ── storage-sqlite
4,707.70 MB ── vsize
---

Version-Release number of selected component (if applicable):
Firefox 24

How reproducible:

Steps to Reproduce:
1. Customer can reproduce on their RHEVM environment by accessing RHEV-M portal and after several days the above issue occurs in KDE. When using LXDE it happens after half and hour or so.

Actual results:
High memory usage in FF when using RHEVM

Expected results:


Additional info:
This could also be an issue in downstream RHEL7 which would potentially be a much larger issue- but not tested yet - cu will be able to check once the RHEL7 beta is released publicly.

Comment 1 Pieter Demmers 2013-12-02 03:54:32 UTC
This issue has also been confirmed to occur with FF25

Comment 2 Pieter Demmers 2013-12-09 02:06:43 UTC
Tested by Colin on FF21 - and issue does not occur - so something in FF24/25 (and possibly 22/23 but these are not available so cannot test).

Comment 4 Martin Stransky 2013-12-19 08:06:25 UTC
Can you please follow steps from https://bugzilla.redhat.com/show_bug.cgi?id=1044010#c11 ?

Thanks!

Comment 5 Martin Stransky 2014-01-07 10:50:17 UTC
Please also try to set "javascript.options.baselinejit.content" to false in about:config.

Comment 6 Pavel Novotny 2014-01-15 18:45:36 UTC
Hi Martin, I measured the memory consumption of Firefox 24 from the erratum [1] and it still takes a lot more RAM than upstream Firefox 26 [2] -> 1,513.50 MB vs. 507.42 MB.

Here's my testflow:
For one hour I opened two tabs, each with different RHEV-M 3.3 instance and during the time I just clicked here and there to avoid to be automatically logged out.
A clean separate profile was used for each browser.
No safe mode.
Client machine: updated RHEL 6.5 x86_64 (Xvfb, Openbox WM, x11vnc)

I left the defaults in about:config :

javascript.options.baselinejit.chrome: false
javascript.options.baselinejit.content: false
javascript.options.jit_hardening: true

Outputs of about:memory are attached.

Let me know if you want access to the testing machine, I'll provide.


[1] https://errata.devel.redhat.com/advisory/16744
[2] ftp://ftp.mozilla.org/pub/firefox/releases/26.0/linux-x86_64/en-US/firefox-26.0.tar.bz2

Comment 7 Pavel Novotny 2014-01-15 18:47:44 UTC
Created attachment 850637 [details]
about:memory of Firefox 24.2.0 (firefox-24.2.0-6.el6_5.x86_64)

Comment 8 Pavel Novotny 2014-01-15 18:48:45 UTC
Created attachment 850638 [details]
about:memory of upstream Firefox 26.0

Comment 11 Martin Stransky 2014-01-16 08:15:29 UTC
Thanks for the feedback. This bug is about Fedora packages (Friefox 26 we ship in Fedora). If you have a problem with RHEL, please file a new bug for it.

Thanks!

Comment 13 Martin Stransky 2014-01-16 12:47:19 UTC
Anyway, I'm unable to reproduce it on Fedora 19/x86_64 and official Fedora build (firefox-26.0-2.fc19.x86_64), with baseline jit enabled. It takes ~700MB. Maybe a different RHEV instance behaves differently or it's an issue under VM/vnc session.

Comment 14 Martin Stransky 2014-01-16 12:48:41 UTC
Please also test it safe-mode (firefox -safe-mode). It may be caused by some installed add-ons.

Comment 15 Jan Horak 2014-01-16 13:30:41 UTC
I see a lot of orphan nodes in DOM consuming the most of memory. This usually points to webapp bug. The safe mode is worth of try definitely.

Comment 16 Pavel Novotny 2014-01-16 14:04:08 UTC
(In reply to Martin Stransky from comment #11)
> Thanks for the feedback. This bug is about Fedora packages (Friefox 26 we
> ship in Fedora). If you have a problem with RHEL, please file a new bug for
> it.
> 
> Thanks!

Sorry, I missed this bug is for Fedora, not RHEL.
I created new bug 1054242 just for RHEL 6.5.

Comment 17 Martin Stransky 2014-02-11 14:22:21 UTC
Firefox 27 has been already released for Fedora and it handles the image better, so closing.

Comment 21 Martin Stransky 2014-03-13 12:22:07 UTC
Yes, the latest Firefox package shows the same problem but it's not so visible because the memory is maintained better.

Comment 23 Martin Stransky 2014-08-25 12:28:55 UTC
Should be fixed now by the Firefox 31 update.


Note You need to log in before you can comment on or make changes to this bug.