If GPU process dies before InitRendering then subsequent ReinitRendering fails
Categories
(Core :: Graphics, defect)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox-esr91 | --- | unaffected |
| firefox-esr102 | --- | fixed |
| firefox101 | --- | wontfix |
| firefox102 | --- | fixed |
| firefox103 | --- | fixed |
People
(Reporter: jnicol, Assigned: jnicol)
References
(Regression)
Details
(Keywords: regression)
Attachments
(1 file, 1 obsolete file)
|
48 bytes,
text/x-phabricator-request
|
pascalc
:
approval-mozilla-release+
pascalc
:
approval-mozilla-esr102+
|
Details | Review |
I discovered this while investigating bug 1772839. I commented out the DestroyEGLContext line here. This means that when you switch to a new tab, pausing the old compositor does not destroy the EGL surface. Therefore when we attempt to resume the new compositor, it fails, and we end up restarting the GPU process. This could occur in the wild if we encounter a WebRender error during initialization.
Because the GPU process has died while the content process is in the middle of RecvInitRendering, creating the WebRenderLayerManager fails, and we set mLayersConnected = Some(false) here.
Once the GPU process has been restarted, we call ReinitRendering. However, due to this line (introduced in bug 1728062) we exit early. This means the new tab forever remains in an unusable state.
If we changed the early-exit condition to if (mLayersConnected.isNothing()) that would fix this. (As the value is Some(false)). Sotaro, do you remember if doing that would still fix bug 1728062?
Updated•4 years ago
|
Comment 1•4 years ago
|
||
Set release status flags based on info from the regressing bug 1728062
Updated•4 years ago
|
Updated•4 years ago
|
Updated•4 years ago
|
| Assignee | ||
Comment 2•4 years ago
|
||
In bug 1728062 we made it so that we that we skip
BrowserChild::ReinitRendering if the BrowserChild is not connected to
a compositor. This was in order to avoid initializing the compositor
for windowless browsers.
However, in cases where the GPU process dies before an initial
InitRendering has completed, then the BrowserChild will also be left
not connected to a compositor, with mLayersConnected == Some(false).
ReinitRendering will be called once the new GPU process has been
launched, but due to this condition we will exit early, and the tab
will be left in an unusable state.
To fix this, this patch changes the early return condition to only
check for mLayersConnected.isNothing(), ie we never even attempted to
initialize rendering. When it is Some(false), ie we attempted and
failed, then ReinitializeRendering is still executed.
Updated•4 years ago
|
Comment 4•4 years ago
•
|
||
(In reply to Jamie Nicol [:jnicol] from comment #0)
If we changed the early-exit condition to
if (mLayersConnected.isNothing())that would fix this. (As the value isSome(false)). Sotaro, do you remember if doing that would still fix bug 1728062?
Hmm, it does not fix bug 1728062:( The problem is that "mLayersConnected == Some(false)" has the following 2 meanings.
- [1] parent side does not request to connect layers.
- [2] parent side requested to connect layers, but the connect was failed.
We need to distinguish between [1] and [2]. And also need to take care crash before InitRendering.
Comment 5•4 years ago
|
||
Updated•4 years ago
|
| Assignee | ||
Comment 6•4 years ago
|
||
Thanks Sotaro. Should we back out my patch and land yours instead?
Comment 7•4 years ago
|
||
Sorry for my slow reply. It seems not necessary. I am going to create a new bug for the patch soon.
| Assignee | ||
Comment 8•4 years ago
|
||
Sounds good. thanks!
Updated•4 years ago
|
Updated•4 years ago
|
Comment 9•4 years ago
|
||
| bugherder | ||
Updated•4 years ago
|
| Assignee | ||
Comment 10•4 years ago
|
||
I think we should uplift this (and bug 1774815). I'm concerned that due to bug 1768197 users could be left with blank unusable tabs as a result.
| Assignee | ||
Comment 11•4 years ago
|
||
Comment on attachment 9281797 [details]
Bug 1774201 - Stop skipping ReinitRendering if previous attempt failed. r?#gfx-reviewers
Beta/Release Uplift Approval Request
- User impact if declined: Users could be left with blank unusable tabs if they encounter a webrender error when initializing a new tab. The patch from bug 1774815 is also required as this patch alone will regress bug 1728062
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Nightly?: Yes
- Needs manual test from QE?: No
- If yes, steps to reproduce:
- List of other uplifts needed: Bug 1774815
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): Ensures we reinitialize the compositor in more circumstances. This was the old behaviour and worked correctly.
- String changes made/needed:
- Is Android affected?: Yes
Comment 12•4 years ago
|
||
Comment on attachment 9281797 [details]
Bug 1774201 - Stop skipping ReinitRendering if previous attempt failed. r?#gfx-reviewers
We are out of the beta cycle and releng is currently merging mozilla-beta to mozilla-release before we build our RC. Morphing this into a release build uplift request.
Comment 13•4 years ago
|
||
Comment on attachment 9281797 [details]
Bug 1774201 - Stop skipping ReinitRendering if previous attempt failed. r?#gfx-reviewers
The impact of the bug in comment #10 looks much more serious to me than the S3 severity set, I am taking it in our RC build, thanks!
Updated•4 years ago
|
Updated•4 years ago
|
Comment 14•4 years ago
|
||
| bugherder uplift | ||
Comment 15•4 years ago
|
||
| bugherder uplift | ||
Description
•