Massive memory leak and hang in Firefox GPU process
Categories
(Core :: Graphics, defect, P1)
Tracking
()
People
(Reporter: tdulcet, Assigned: ahale)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
For more than a year now, I have had this issue where the Firefox GPU process occasionally hangs, which causes Firefox to become very slow and some tabs to become unresponsive. Restarting Firefox usually resolves the issue. Normally it occurs very infrequently (less than once a month), but it has occurred twice so far today. I also noticed that the GPU process was using an inordinate amount of memory (see attached screenshot)
I tried to record a profile, but the profile importer just hangs on the loading animation. The browser console also opens a blank window. I am currently using Firefox 122.0.1.
Comment 1•1 year ago
|
||
The Bugbug bot thinks this bug should belong to the 'Core::Graphics' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
Reporter | ||
Comment 2•1 year ago
|
||
I attached the memory report, but I do not see what is using the 37 GB.
Reporter | ||
Comment 4•1 year ago
|
||
Attached is the requested about:support
information.
Comment 5•1 year ago
|
||
An integrated and a discrete gpu, I wonder if that is related.
Comment 6•11 months ago
|
||
Ashley, I think you've been looking into similar bugs as this? Do you have any thoughts on this? Does it sound familiar? Thoughts on moving it forward?
Updated•11 months ago
|
Assignee | ||
Updated•11 months ago
|
Updated•9 months ago
|
Assignee | ||
Comment 7•9 months ago
|
||
My suspicion from the about:support is that the Intel UHD 630 driver (from 2021) might not have the best interactions with the NVIDIA RTX 2060 driver (from 2023), as those are probably different feature levels in terms of WDDM, but the interesting part to me is that the Firefox Task Manager is showing the bloated GPU process memory, this is different than the other bugs I've been looking at where the memory usage only shows up in system level monitoring tools and not in the builtin about:processes (Firefox Task Manager).
I'm not sure how to move this forward at this time, I'll be thinking about it as I investigate the other memory usage bugs.
Firefox 126.0 (Build ID 20240509170740) mozilla-MSIX Windows 11
AMD Ryzen 7 PRO 6850U with Radeon Graphics
Firefox open for a while, browsing, watching videos when computer goes
"You're running low on disk space"
gpu process sitting at over 20GB reserved memory -> about:memory screenshot
(memory usage also showed in the about:processes here)
Assignee | ||
Comment 9•8 months ago
|
||
(In reply to Teal Dulcet [:tdulcet] (TB Council) from comment #2)
Created attachment 9379187 [details]
memory-report.json.gzI attached the memory report, but I do not see what is using the 37 GB.
Yeah, it looks similar to the decoder device leak I was able to repro in https://bugzilla.mozilla.org/show_bug.cgi?id=1847453#c47 but that bug is on AMD drivers, perhaps there is a similar leak on Intel UHD 630 drivers or NVIDIA RTX 2060 drivers but it would surprise me.
There have been changes in Firefox Nightly recently to try to work around https://bugzilla.mozilla.org/show_bug.cgi?id=1847453 which might reduce the problem if it is of a similar nature.
This part of your GPU process listing is key:
8.21 MB ── d3d11-shared-textures
0.00 MB ── gfx-d2d-vram-draw-target
0.00 MB ── gfx-d2d-vram-source-surface
37,629.26 MB ── gpu-committed
0.00 MB ── gpu-dedicated
5,579.38 MB ── gpu-shared
232.11 MB ── heap-allocated
1.00 MB ── heap-chunksize
311.00 MB ── heap-mapped
38,327.88 MB ── private
18,579.29 MB ── resident
18,578.17 MB ── resident-unique
4.27 MB ── shmem-allocated
36.72 MB ── shmem-mapped
267.71 MB ── system-heap-allocated
0 ── unresolved-ipc-responses
2,140,627.40 MB ── vsize
130,618,014.06 MB ── vsize-max-contiguous
Reporter | ||
Comment 10•8 months ago
|
||
Thanks for the information. As I noted in comment 0, the bug happens infrequently, but I can post again next time it occurs if needed.
The memory used by GPU process as listed in about:processes
is always higher than I would expect (not sure if it is related to this bug). It usually starts at about 3 GB when I open Firefox and then increases up to around 7 GB over the course of the day. When combined with the leak described in bug 1834526 comment 28, this causes Firefox to use a lot memory on my system in general.
Updated•8 months ago
|
Assignee | ||
Updated•7 months ago
|
Assignee | ||
Updated•7 months ago
|
Assignee | ||
Comment 11•1 month ago
|
||
Sotaro, do you think this bug is still relevant? I think the fixes to decoder device reuse probably resolve this bug.
Assignee | ||
Comment 12•1 month ago
|
||
I believe this is a duplicate of 1847453 so I am closing it as such.
Comment 13•1 month ago
|
||
(In reply to Ashley Hale [:ahale] from comment #11)
Sotaro, do you think this bug is still relevant? I think the fixes to decoder device reuse probably resolve this bug.
Reuse decoder device problem happened at Firefox 126 by Bug 1888354. And the problem is addressed by Firefox 126.0.1 by Bug 1897006.
Description
•