Improve asynchronicity of content process startup
Categories
(GeckoView Graveyard :: Sandboxing, enhancement, P1)
Tracking
(firefox74 fixed)
Tracking | Status | |
---|---|---|
firefox74 | --- | fixed |
People
(Reporter: bugzilla, Assigned: bugzilla)
References
Details
(Whiteboard: [geckoview:m1911] [geckoview:m1912][geckoview:m74])
Attachments
(4 files)
We need to hook up content process startup to route through the launcher thread. bholley wrote a POC patch, but it was a POC.
There's a bunch of synchronous stuff in GeckoProcessManager
that should be made more async.
Assignee | ||
Updated•6 years ago
|
Comment 1•6 years ago
|
||
Aaron says he will be working on this bug in November.
Assignee | ||
Comment 2•6 years ago
|
||
Note to self: as I do this, I need to be aware of exception handling and making sure that they are caught and routed through GeckoResult
.
Assignee | ||
Updated•6 years ago
|
Assignee | ||
Comment 3•6 years ago
|
||
Since XPCOMEventTarget
uses JNI, this patch makes it possible for consumers to
retrieve and invoke methods on one without needing to worry about whether JNI
is actually up yet.
To achieve this, we create the IXPCOMEventTarget
interface, and observe that
both of its methods can be handled by a proxy if JNI is not ready:
- Calls to
dispatch
may be enqueued until JNI is up; - Observe that, when JNI is not up yet, the result of
isOnCurrentThread
can never betrue
.
Once JNI is up and the event targets have been resolved, the proxies are
replaced with the real, concrete XPCOMEventTarget
s.
Assignee | ||
Comment 4•6 years ago
|
||
This patch adds a Dispatcher
implementation that allows us to create
GeckoResult
s that will dispatch to the XPCOM launcher thread.
Depends on D57837
Assignee | ||
Comment 5•6 years ago
|
||
The primary purpose of this patch is to convert the internal sequence of
service binding and invoking of start
to asynchronously run on the XPCOM
launcher thread via GeckoResult
. Because more of the code now runs on the same
thread, many of these methods no longer need to be synchronized
.
Disconnecting via unbind
is also modified to use the launcher thread and
GeckoResult
.
Note that no changes have been made yet to enable multiple processes of the
same type; those changes will be made in bug 1595834.
Depends on D57838
Assignee | ||
Comment 6•6 years ago
|
||
Now that everything in GeckoProcessManager
runs on the XPCOM launcher thread,
GeckoThread
should just call GeckoProcessManager.preload()
directly.
Depends on D57839
Updated•6 years ago
|
Updated•6 years ago
|
Comment 8•6 years ago
|
||
Backed out for geckoview failures
Backout link: https://hg.mozilla.org/integration/autoland/rev/a7091013d0879e555e138f7b99217ea21b4d35ad
Log link: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=284302017&repo=autoland&lineNumber=12397
Assignee | ||
Updated•6 years ago
|
Comment 10•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/2f6df46484dc
https://hg.mozilla.org/mozilla-central/rev/de9a496180f9
https://hg.mozilla.org/mozilla-central/rev/d6d2afaee49d
https://hg.mozilla.org/mozilla-central/rev/6fcef35f1cf4
Comment 11•3 years ago
|
||
Moving content process management bugs to the new GeckoView::Sandboxing component.
Updated•1 year ago
|
Description
•