Closed Bug 1608235 Opened 5 years ago Closed 5 years ago

Crash in [@ egl::ValidateStreamConsumerGLTextureExternalAttribsNV]

Categories

(Core :: Graphics: WebRender, defect, P1)

Unspecified
Windows 10
defect

Tracking

()

RESOLVED FIXED
mozilla74
Tracking Status
firefox-esr68 --- unaffected
firefox72 --- unaffected
firefox73 --- unaffected
firefox74 + fixed

People

(Reporter: marcia, Assigned: sotaro)

References

(Regression)

Details

(Keywords: crash, regression)

Crash Data

Attachments

(1 file, 1 obsolete file)

This bug is for crash report bp-1212a2ca-9f2c-43ec-9b91-253540200108.

Seen while looking at nightly crash stats - gpu crashes started in 20200107095722: https://bit.ly/2seGfwY

Possible regression range based on build id: https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=bc5880b621d585ca49be49e07ee14dd32153c01b&tochange=e728bf01a2b60414e18ac3abed8af55d5ab35924

Top 10 frames of crashing thread:

0 libglesv2.dll egl::ValidateStreamConsumerGLTextureExternalAttribsNV gfx/angle/checkout/src/libANGLE/validationEGL.cpp:2634
1 libglesv2.dll EGL_StreamConsumerGLTextureExternalAttribsNV gfx/angle/checkout/src/libGLESv2/entry_points_egl_ext.cpp:785
2 xul.dll mozilla::wr::RenderDXGITextureHostOGL::EnsureLockable gfx/webrender_bindings/RenderD3D11TextureHostOGL.cpp
3 xul.dll mozilla::wr::RenderDXGITextureHostOGL::Lock gfx/webrender_bindings/RenderD3D11TextureHostOGL.cpp:208
4 xul.dll mozilla::wr::wr_renderer_lock_external_image gfx/webrender_bindings/RendererOGL.cpp:51
5 xul.dll webrender_bindings::bindings::{{impl}}::lock gfx/webrender_bindings/src/bindings.rs:439
6 xul.dll webrender::renderer::Renderer::render_impl gfx/wr/webrender/src/renderer.rs:3102
7 xul.dll webrender::renderer::Renderer::render gfx/wr/webrender/src/renderer.rs:2921
8 xul.dll webrender_bindings::bindings::wr_renderer_render gfx/webrender_bindings/src/bindings.rs:654
9 xul.dll mozilla::wr::RendererOGL::UpdateAndRender gfx/webrender_bindings/RendererOGL.cpp:151

@sotaro: This looks like a high frequency crash. I couldn't immediately spot a change that would cause this, but since you changed the logging in https://bugzilla.mozilla.org/show_bug.cgi?id=1607129, I thought you might have some ideas here.

Blocks: wr-74
Flags: needinfo?(sotaro.ikeda.g)
Priority: -- → P1

OK, I take a look. I wonder if it might be related to device reset.

Assignee: nobody → sotaro.ikeda.g
Flags: needinfo?(sotaro.ikeda.g)

Crash happened at EGL_StreamConsumerGLTextureExternalAttribsNV(). It uses "gl::Context *context = gl::GetValidGlobalContext()" for validation check. The context seemed to be nullptr.

ANGLE has similar checks in the followings.

  • EGL_StreamConsumerGLTextureExternalKHR()
  • EGL_StreamConsumerAcquireKHR()
  • EGL_StreamConsumerReleaseKHR()
  • EGL_StreamConsumerGLTextureExternalAttribsNV()

They affects only to

  • RenderDXGITextureHostOGL::EnsureLockable()
  • RenderDXGIYCbCrTextureHostOGL::EnsureLockable()

When ANGLE detects a context lost, GetValidGlobalContext() returns nullptr.
https://searchfox.org/mozilla-central/rev/c52d5f8025b5c9b2b4487159419ac9012762c40c/gfx/angle/checkout/src/libANGLE/Thread.cpp#99

The following does not handle a case that context is nullptr. All another functions seems to have a nullptr check.

Attached file Bug 1608235 - Add nullptr check (obsolete) —

Bug 1606046 is probably the change that brought us here, but this is a bug we should fix.

Blocks: 1606046
No longer blocks: webgl-ipc-refactor
No longer blocks: 1606046
Regressed by: 1606046
Has Regression Range: --- → yes
Pushed by jgilbert@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b09849127a4f [ANGLE] Validate `context` before use. r=sotaro
Attachment #9121458 - Attachment is obsolete: true
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla74
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: