This modifies Browser/ChildProcessHost and ChildThreadImpl to support
child processes which never establish a legacy IPC Channel, and
modifies UtilityProcessHost and UtilityThreadImpl to take advantage of
this.
This makes utility processes the first type of process to be completely
free of legacy IPC. GPU processes can follow shortly hereafter.
To facilitate this change, a few other details are modified here:
- BrowserChildProcessObserver no longer exposes a separate
BrowserProcessHostConnected event. The only two consumers are
migrated to BrowserChildProcessLaunchedAndConnected. This avoids
potential re-entrancy issues when launching a process, since any
hosts not using legacy IPC are considered to be connected
synchronously as soon as launch is started.
- Browser/ChildProcessHost no longer acknowledges the PID received
from the child process in IPC::Listener::OnChannelConnected,
instead using the PID exposed directly from the
ChildProcessLauncher. This is consistent whether or not the
host creates a legacy IPC channel.
Bug: 616980, 993189
Change-Id: I881db61db335b70b658fe0dbf0c149703e7219e4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2959467
Commit-Queue: Ken Rockot <rockot@google.com>
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Robert Kaplow <rkaplow@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
Reviewed-by: Alex Gough <ajgo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#893209}