Closed Bug 1218118 Opened 9 years ago Closed 8 years ago

Youtube playing ends in out of memory in non E10s with D3D9

Categories

(Core :: Graphics, defect)

44 Branch
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 1234047
Tracking Status
e10s - ---

People

(Reporter: micha.postbox, Unassigned)

References

Details

(Keywords: regression, Whiteboard: [gfx-noted])

Attachments

(6 files)

User Agent: Mozilla/5.0 (Windows NT 10.0; rv:44.0) Gecko/20100101 Firefox/44.0
Build ID: 20151024030248

Steps to reproduce:

Playing youtube with D3D9 set to true to enable HWA in non E10s mode.


Actual results:

During youtube playing the memory consumption increases suddenly. Some seconds all is ok, but suddenly the memory consumption starts to increase until there is no free memory and heavy hdd activity. The memory will released as soon i click "pause" or the video ends.


Expected results:

Memory consumption should stay in a normal range.
Attached image 1.JPG
As you see in the pictures the memory will be released if i click pause.
Attached image 2.JPG
GPU memory
Attached image 4.JPG
high memory consumption in action.
Is this something that used to work OK and has since regressed?
Flags: needinfo?(micha.postbox)
I was forced to activate d3d9 pref to get HWA enabled with on non XP systems some times ago. (i would prefer a separate pref for this restriction...) At this time it was still ok. I will try to check since when this occurs in next days.

If this happens in the page lists "modified" value increases dramatically.
Flags: needinfo?(micha.postbox)
Good to know. I'm assuming you forced acceleration on via the layers.acceleration.force-enabled pref?

The mozregression tool can automate hunting down the regression range - http://mozilla.github.io/mozregression/. If it's easy to reproduce, it shouldn't take very long.

Something like |mozregression --good 2015-10-01 --pref "layers.acceleration.force-enabled:true"| should work (feel free to use whatever date you want for when it was last known to be good).
No i enabled only layers.prefer-d3d9 in a clean profile.

Here we have the problem:

https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=530ecc275dd9849fa57c70bd9a076f53ef13652b&tochange=f10665af6c505ec38a3dff34f147a6535c4c3107

A lot of changesets in Bug 1143575.
tracking-e10s: - → ---
Thanks for tracking it down!

Robert, can you please take a look at this regression?
Blocks: 1143575
Status: UNCONFIRMED → NEW
Component: Untriaged → Graphics
Ever confirmed: true
Flags: needinfo?(roc)
Keywords: regression
Product: Firefox → Core
One other thing that might help debug the issue would be if you could attach an about:memory dump from before the browser crashes.
Flags: needinfo?(micha.postbox)
Flags: needinfo?(micha.postbox)
Whiteboard: [gfx-noted]
Assignee: nobody → roc
Flags: needinfo?(roc)
If this happens in e10s mode, as well, please re-nom for tracking.
tracking-e10s: --- → -
My Windows laptop is flaky so I'm having difficulty working on this bug.
I got things working well enough to try to reproduce this, but I can't. I'm 50 minutes into https://www.youtube.com/watch?v=-_f2Enn8x5s. Memory usage is gradually increasing but the increase is all under "media/resources" which is unrelated to D3D9 or e10s. The increase is very slow; after 50 minutes I have 850MB committed allocations and 471 explicit allocations, of which 210MB are under media/resources.

So I guess I'm not seeing the problem reported in this bug.
TheRave, does this problem occur on some videos but not others? Does it occur on https://www.youtube.com/watch?v=-_f2Enn8x5s for you?

I'm testing on 45.0a1 (a bit old but newer than the build on which this was reported).
Flags: needinfo?(micha.postbox)
After 2 minutes of playing i had to stop the video to release the memory. Fx Nightly 20151130.
Flags: needinfo?(micha.postbox)
Attached image 301115.JPG
Alright I think we need to use DMD to narrow down the heap-unclassified.
Is somewhere already a DMD build available?
If you're building Firefox you can make your own with the instructions here: https://developer.mozilla.org/en-US/docs/Mozilla/Performance/DMD

Also I'll make a try build which you can use, though it looks a bit painful:
https://bugzilla.mozilla.org/show_bug.cgi?id=936784#c69

The builds will show up here after a while:
https://treeherder.mozilla.org/#/jobs?repo=try&revision=2e248ccd9b15

If that doesn't work needinfo me and I'll try to find another developer with a Windows machine to help. I'm about to hit the road and won't be bringing my Windows machine with you.
The debug build was crashing immediately after start the youtube playing.

The symbols was expendanded as recommended.

The opt works. But as soon i start the nightly with this options:

D:\Nightly>set MOZ_REPLACE_MALLOC_LIB=dmd.dll
D:\Nightly>set DMD=1
D:\Nightly>set _NT_SYMBOL_PATH=d:\ffsymbols
D:\Nightly>D:\Nightly\firefox.exe -no-remote -p Test

...nightly starts very slow and it means really really slow...minutes. I have constantly 47% CPU load here which means 100% one core. The loading of youtube takes 10 minutes. Playing in slow motion every two minutes 2 seconds.

Also i tried to trigger the dmd output via bookmarklet javascript:DMDReportAndDump("out.dmd"), nut there is no output file...not in working dir and not in profile dir.

Under this circumstances i have no idea how i can generate the out.dmd under live environment conditions.
Regarding the bookmarklet: ReferenceError: DMDReportAndDump is not defined. Anyway as long all runs in slow motion i see no possibilities to narrow this down here.
Ok i have now some dmd reports. Not sure if the problem is recorded there. I played 30sec of the video in 30 minutes or so and my memory consumption has done something but is not so nice to recognize as in realtime.

Contains the files only firefox related data or is there still windows related stuff in the files? Then i would upload this somewhere.
Thanks for trying!!! Please upload them somewhere.
Anthony, can you please help find a new owner for this?
Flags: needinfo?(ajones)
TheRave, is this still a problem? It was reported just after D3D9 was enabled on e10s and IIRC there have been fixes in the meanwhile.
Flags: needinfo?(micha.postbox)
Looks like memory consumption is stable with D3D9 = true now. I have D3D9 disabled since December 2015, because it was really annoying. If i have some minutes on weekend i can check with mozregression since when it is fixed.
Flags: needinfo?(micha.postbox)
Ok here we go. It was fixed since 2016-01-12 in mozilla central.

Mozregression tracks the fix down to mozilla-inbound at:
https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=8e52730bd8ee9d9037f9e278b0e30631c4f85e5b&tochange=bc9f37187bbf2232c9a438a1137473e7fe43ce17

Whatever the bug 1234047 fixed, it fixed also the memory consumption problem at youtube with d3d9=true on non e10s.
Status: NEW → RESOLVED
Closed: 8 years ago
Flags: needinfo?(ajones)
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: