Closed Bug 1376527 Opened 2 years ago Closed 2 years ago

Crash in mozilla::wr::LockExternalImage

Categories

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

56 Branch
Unspecified
macOS
defect
Not set
critical

Tracking

()

RESOLVED FIXED
mozilla56
Tracking Status
firefox-esr52 --- unaffected
firefox54 --- unaffected
firefox55 --- unaffected
firefox56 --- fixed

People

(Reporter: marcia, Assigned: sotaro)

References

(Depends on 1 open bug)

Details

(Keywords: crash, reproducible)

Crash Data

Attachments

(2 files, 1 obsolete file)

This bug was filed from the Socorro interface and is 
report bp-3afeee47-cff4-4bb8-acf1-067ad0170627.
=============================================================

Seeing this crash with the latest nightly Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:56.0) Gecko/20100101 Firefox/56.0 ID:20170627100238 CSet: 53477d584130945864c4491632f88da437353356

STR:
1. Click on Firefox nightly in the dock, or a firefox window
2. Crash - 100% reproducible. WR is enabled.
:marcia, is the crash happen on another platform than mac?
Flags: needinfo?(mozillamarcia.knous)
See Also: → 1376532
(In reply to Sotaro Ikeda [:sotaro] from comment #1)
> :marcia, is the crash happen on another platform than mac?

:marcia, can you also check what will happen on debug build?
(In reply to Sotaro Ikeda [:sotaro] from comment #1)
> :marcia, is the crash happen on another platform than mac?

Not sure. I can check next week when I have access again to a Windows machine.
Flags: needinfo?(mozillamarcia.knous)
When I checked windows and linux, I did not see the crash for now. I do not have environment of mac this week :(
(In reply to Sotaro Ikeda [:sotaro] from comment #2)
> (In reply to Sotaro Ikeda [:sotaro] from comment #1)
> > :marcia, is the crash happen on another platform than mac?
> 
> :marcia, can you also check what will happen on debug build?

I can reproduce the crash in a debug build using my main Nightly profile, but haven't been able to do it with a clean profile. I will attach the terminal output.
Attached file debug.txt
Adding to my STR in Comment 0, I do minimize the window first. When I do that and click on the icon or minimized window I get an immediate crash.
I am going to look into it next week.
Assignee: nobody → sotaro.ikeda.g
Nightly 56 build 20170701100250 @ macOS 10.12.5 Darwin 16.6.0
Can reliably reproduce with attachment of bug 1305298 comment 0 with webrender+webrendest enabled.

Meldungs-ID 	Sendedatum
bp-9311c21a-cd02-4615-9e40-28d0e0170701 01.07.17 23:27
bp-71060776-f272-4da1-9f73-d27c70170701 01.07.17 23:26
The crash seemed to happen when mWidget->PreRender() returned false in RendererOGL::Render().

When mWidget->PreRender() returned false, RendererOGL::Render() does not call wr_renderer_render(). It means that webrender::renderer does not handle pending_texture_updates. But even in this case, RenderThread assumed that pending_texture_updates was handled and call NotifyDidRender().
  https://dxr.mozilla.org/mozilla-central/source/gfx/webrender_bindings/RenderThread.cpp#174

Then CompositorBridgeParent::NotifyDidCompositeToPipeline() called and it calls WebRenderCompositableHolder::Update(). WebRenderCompositableHolder::Update() assumes external images' end of usages from epoch. But it is not correct when mWidget->PreRender() returned false.
mWidget->PreRender() could return false only on nsChildView::PreRender() on mac.
Attachment #8882971 - Flags: review?(nical.bugzilla)
Attachment #8882971 - Flags: review?(nical.bugzilla) → review+
Pushed by sikeda@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/39b8e61c50e0
Do not call NotifyDidRender when RendererOGL::Render() returned false r=nical
https://hg.mozilla.org/mozilla-central/rev/39b8e61c50e0
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
You need to log in before you can comment on or make changes to this bug.