Closed Bug 1549311 Opened 2 years ago Closed 1 month ago

Crash in [@ @0x0 | mozilla::layers::DirectMapTextureSource::UpdateInternal]

Categories

(Core :: Graphics: Layers, defect, P3)

Unspecified
Linux
defect

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: gsvelto, Unassigned)

References

(Regression)

Details

(Keywords: crash, regression)

Crash Data

This bug is for crash report bp-153889b7-7647-46d4-a40f-c7c640190505.

Top 10 frames of crashing thread:

0  @0x0 
1 libxul.so mozilla::layers::DirectMapTextureSource::UpdateInternal gfx/layers/opengl/TextureHostOGL.cpp:401
2 libxul.so mozilla::layers::CompositorOGL::CreateDataTextureSourceAroundYCbCr gfx/layers/opengl/CompositorOGL.cpp:1887
3 libxul.so mozilla::layers::BufferTextureHost::EnsureWrappingTextureSource gfx/layers/composite/TextureHost.cpp:672
4 libxul.so mozilla::layers::BufferTextureHost::PrepareTextureSource gfx/layers/composite/TextureHost.cpp:761
5 libxul.so mozilla::layers::ImageHost::UseTextureHost gfx/layers/composite/ImageHost.cpp:69
6 libxul.so mozilla::layers::CompositableParentManager::ReceiveCompositableUpdate gfx/layers/ipc/CompositableTransactionParent.cpp:178
7 libxul.so mozilla::layers::ImageBridgeParent::RecvUpdate gfx/layers/ipc/ImageBridgeParent.cpp:195
8 libxul.so mozilla::layers::PImageBridgeParent::OnMessageReceived ipc/ipdl/PImageBridgeParent.cpp:318
9 libxul.so mozilla::ipc::MessageChannel::DispatchMessage ipc/glue/MessageChannel.cpp:2151

We're crashing at address 0x0 so I guess this is trying to jump into a null pointer at:

https://hg.mozilla.org/mozilla-central/annotate/9419be649effc5bc67eb3d6fce1db46caa7fae7e/gfx/layers/opengl/TextureHostOGL.cpp#l401

This and a couple more comments in the crash reports mention that this happens when trying to play video after resuming from suspend:

Step to reproduce - Launch, suspend PC, resume, get corrupted screen with [GFX1-]: [OPENGL] Failed to init compositor with reason: FEATURE_FAILURE_OPENGL_CREATE_CONTEXT, click Toggle reset in About:support, start any video on Youtube

The priority flag is not set for this bug.
:jbonisteel, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(jbonisteel)
Flags: needinfo?(jbonisteel)
Priority: -- → P3

Hello, i one of persons who affected by this bug. So, its all started with this bug - https://bugzilla.mozilla.org/show_bug.cgi?id=1492580 which caused hardlocks in Firefox in certain (and not rare) cases. Once it was fixed follow ups started to appear, like this one - https://bugzilla.mozilla.org/show_bug.cgi?id=1511508 - situations (suspend\resume, user switch) which previously caused hardlocks started to cause display corruptions (wrong tab content displayed, picture stretched in extreme proportions, color inversions). Buts its pretty much easy "fix" by pressing Trigger Device Reset in about:support. However, after yet another some time attempt to play video once whole sequence of actions completed started to, sometimes, crash browser with this signature.

Additional notes :

HW_COMPOSITING
force_enabled by user: Force-enabled by pref
blocked by env: Acceleration blocked by platform
OPENGL_COMPOSITING
force_enabled by user: Force-enabled by pref

OS is Ubuntu 19.04 (same problem was on Ubuntu 18.10), X11 and driver is Nvidia driver is 418.56.0.0, albeit its doesnt seems to affect situation at all, since a had similar problems on both 415 and 410 and earlier versions of Nvidia driver.

(In reply to Gabriele Svelto [:gsvelto] from comment #0)

https://hg.mozilla.org/mozilla-central/annotate/9419be649effc5bc67eb3d6fce1db46caa7fae7e/gfx/layers/opengl/TextureHostOGL.cpp#l401

Line was added by bug 1478704.
This sounds related to what we saw previously: bug 1406230 comment 15.

Regressed by: 1478704
See Also: → 1406230

(Matt Woodrow (:mattwoodrow) from bug 1406230 comment 17)

I think we want to check before using DirectMapTextureSource, like Doug suggested in bug 1406230 comment 12.

(In the end no patch was landed as the bug was no longer reproducible.)

I think I'm seeing a similar crashes after resume, at least the crash report links to this and it sounds similar. Sometimes its a crash, sometimes its just corrupt windows where the drawing goes kinda all over and you can't really click inside the window but i can close them before they "crash".

I've had similar graphics corruption errors in Gnome after resume though not quite as bad an not causing crashes. Their workaround was to restart the shell to re-initialize the gl buffers or something and I still have to do that from time to time but I can't really do that with firefox. This looks like the bug report, I hope it helps. https://gitlab.gnome.org/GNOME/gnome-shell/issues/654

(In reply to James Gilliland from comment #5)

I think I'm seeing a similar crashes after resume, at least the crash report links to this and it sounds similar. Sometimes its a crash, sometimes its just corrupt windows where the drawing goes kinda all over and you can't really click inside the window but i can close them before they "crash".

I've had similar graphics corruption errors in Gnome after resume though not quite as bad an not causing crashes. Their workaround was to restart the shell to re-initialize the gl buffers or something and I still have to do that from time to time but I can't really do that with firefox. This looks like the bug report, I hope it helps. https://gitlab.gnome.org/GNOME/gnome-shell/issues/654

Clicking "Trigger Device Reset" in about:support actually fixes window corruption, you just need to do it quickly after resume (suspending while on about:support is good idea). This is not new behavior, see Bug 1511508 and Bug 1596577.

This has spiked over the last few weeks. Does anything need to happen here?

Flags: needinfo?(jmathies)
Blocks: gfx-triage
Flags: needinfo?(jmathies)

We're going to fix this by deprecating the gl backend on linux and replace it with webrender.

No longer blocks: gfx-triage

For those affected by this crash: it seems that the majority of the crashes happen to users using closed-source NVidia drivers, switching to regular Mesa drivers might help.

Closing because no crashes reported for 12 weeks.

Status: NEW → RESOLVED
Closed: 1 month ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.