Bug 218769 - GPUProcess does not properly get relaunched after crashing
Summary: GPUProcess does not properly get relaunched after crashing
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-11-10 12:57 PST by Chris Dumez
Modified: 2020-11-11 09:15 PST (History)
10 users (show)

See Also:


Attachments
Patch (28.59 KB, patch)
2020-11-10 13:03 PST, Chris Dumez
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch (28.80 KB, patch)
2020-11-10 13:11 PST, Chris Dumez
no flags Details | Formatted Diff | Diff
Patch (29.24 KB, patch)
2020-11-10 14:10 PST, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2020-11-10 12:57:19 PST
GPUProcess does not properly get relaunched after crashing.
Comment 1 Chris Dumez 2020-11-10 13:03:53 PST
Created attachment 413726 [details]
Patch
Comment 2 Chris Dumez 2020-11-10 13:11:06 PST
Created attachment 413727 [details]
Patch
Comment 3 Geoffrey Garen 2020-11-10 13:24:05 PST
Comment on attachment 413727 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=413727&action=review

> Source/WebKit/UIProcess/GPU/GPUProcessProxy.cpp:86
>  GPUProcessProxy* GPUProcessProxy::m_singleton = nullptr;

Can we use WeakPtr for m_singleton?
Comment 4 Chris Dumez 2020-11-10 13:47:38 PST
(In reply to Geoffrey Garen from comment #3)
> Comment on attachment 413727 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=413727&action=review
> 
> > Source/WebKit/UIProcess/GPU/GPUProcessProxy.cpp:86
> >  GPUProcessProxy* GPUProcessProxy::m_singleton = nullptr;
> 
> Can we use WeakPtr for m_singleton?

In file included from /Volumes/Data/WebKit/OpenSource/WebKitBuild/Release/DerivedSources/WebKit2/unified-sources/UnifiedSource54.cpp:3:
/Volumes/Data/WebKit/OpenSource/Source/WebKit/UIProcess/GPU/GPUProcessProxy.cpp:86:43: error: declaration requires an exit-time destructor [-Werror,-Wexit-time-destructors]
WeakPtr<GPUProcessProxy> GPUProcessProxy::m_singleton;
/Volumes/Data/WebKit/OpenSource/Source/WebKit/UIProcess/GPU/GPUProcessProxy.cpp:86:43: error: declaration requires a global destructor [-Werror,-Wglobal-constructors]

Do you have a proposal to make it work?
Comment 5 Geoffrey Garen 2020-11-10 13:53:07 PST
I *think* NeverDestroyed<WeakPtr<GPUProcessProxy>> should work, since NeverDestroyed avoids exit time destructors and WeakPtr allows assignment.
Comment 6 Chris Dumez 2020-11-10 14:10:09 PST
Created attachment 413739 [details]
Patch
Comment 7 EWS 2020-11-10 15:36:35 PST
Committed r269657: <https://trac.webkit.org/changeset/269657>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 413739 [details].
Comment 8 Radar WebKit Bug Importer 2020-11-10 15:37:20 PST
<rdar://problem/71258139>