Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1011)

Issue 1532423003: Have each SandboxedProcessLauncherDelegate maintain a zygote. (Closed)

Created:
5 years ago by Greg K
Modified:
3 years, 7 months ago
CC:
chromium-reviews, darin-cc_chromium.org, nasko+codewatch_chromium.org, jam, rickyz+watch_chromium.org, creis+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Have each SandboxedProcessLauncherDelegate maintain a zygote. To improve component updates of PPAPI plugins, Chrome needs multiple zygotes. This will allow the PPAPI zygote to be recreated when a plugin is updated. This CL allows Chrome to maintain a zygote for each process type by having each SandboxedProcessLauncherDelegate maintain a class which can communicate with its respective zygote. This CL will be followed up with work to allow customization of zygotes, which will give Chrome the improve component update experience. BUG=569191 Committed: https://crrev.com/3c1e16b490255119b6f70f94d1716645e897b185 Cr-Commit-Position: refs/heads/master@{#370488} Committed: https://crrev.com/afd49a83be5da2df6667a2afd14239d7783aff52 Cr-Commit-Position: refs/heads/master@{#371042}

Patch Set 1 #

Patch Set 2 : Fix mac build #

Patch Set 3 : Fix even more builds #

Patch Set 4 : Fix the android build #

Patch Set 5 : Fix android shell builds #

Patch Set 6 : Fetch sandbox status #

Total comments: 22

Patch Set 7 : Fixups per review #

Patch Set 8 : #

Total comments: 10

Patch Set 9 : #

Patch Set 10 : #

Total comments: 6

Patch Set 11 : Fix IWYU errors #

Total comments: 2

Patch Set 12 : Load and initialize all zygotes on browser startup. #

Total comments: 6

Patch Set 13 : Cleanups per review., #

Total comments: 4

Patch Set 14 : Fixup the namespace and header name. #

Total comments: 5

Patch Set 15 : Cleanup the NaCl defines. #

Patch Set 16 : Correctly initialize the sandbox_binary_ command before launching the zygote. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+834 lines, -598 lines) Patch
M chrome/browser/chrome_browser_main.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +5 lines, -0 lines 0 comments Download
M chrome/browser/memory_details.cc View 1 2 3 4 5 6 2 chunks +1 line, -6 lines 0 comments Download
M chrome/browser/ui/webui/about_ui.cc View 1 2 3 4 5 6 1 chunk +2 lines, -1 line 0 comments Download
M components/nacl/browser/nacl_process_host.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +5 lines, -0 lines 0 comments Download
M components/nacl/browser/nacl_process_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 4 chunks +17 lines, -1 line 0 comments Download
M content/browser/browser_main_loop.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 3 chunks +9 lines, -0 lines 0 comments Download
M content/browser/child_process_launcher.h View 1 2 3 4 5 6 3 chunks +4 lines, -4 lines 0 comments Download
M content/browser/child_process_launcher.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 11 chunks +27 lines, -20 lines 0 comments Download
M content/browser/ppapi_plugin_process_host.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +5 lines, -0 lines 0 comments Download
M content/browser/ppapi_plugin_process_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 4 chunks +23 lines, -2 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +5 lines, -0 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 4 chunks +31 lines, -2 lines 0 comments Download
M content/browser/utility_process_host_impl.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +5 lines, -0 lines 0 comments Download
M content/browser/utility_process_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 6 chunks +28 lines, -2 lines 0 comments Download
A content/browser/zygote_host/zygote_communication_linux.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +92 lines, -0 lines 0 comments Download
A content/browser/zygote_host/zygote_communication_linux.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +460 lines, -0 lines 0 comments Download
A content/browser/zygote_host/zygote_handle_linux.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +17 lines, -0 lines 0 comments Download
M content/browser/zygote_host/zygote_host_impl_linux.h View 1 2 3 4 5 6 7 8 3 chunks +18 lines, -68 lines 0 comments Download
M content/browser/zygote_host/zygote_host_impl_linux.cc View 1 2 3 4 5 6 7 8 9 12 4 chunks +18 lines, -486 lines 0 comments Download
M content/content_browser.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +4 lines, -0 lines 0 comments Download
M content/content_common.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +1 line, -0 lines 0 comments Download
A content/public/browser/zygote_handle_linux.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +21 lines, -0 lines 0 comments Download
M content/public/browser/zygote_host_linux.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +3 lines, -3 lines 0 comments Download
M content/public/common/sandboxed_process_launcher_delegate.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +6 lines, -1 line 0 comments Download
M content/public/common/sandboxed_process_launcher_delegate.cc View 1 2 3 4 5 6 7 1 chunk +4 lines, -2 lines 0 comments Download
A content/public/common/zygote_handle.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +23 lines, -0 lines 0 comments Download

Messages

Total messages: 63 (27 generated)
Greg K
Matt, we can start looking at this first CL to move to a world with ...
5 years ago (2015-12-21 21:19:08 UTC) #3
mdempsky
(I focused mostly on the code outside of zygote_host so far.) https://codereview.chromium.org/1532423003/diff/100001/content/browser/browser_main_loop.cc File content/browser/browser_main_loop.cc (left): ...
5 years ago (2015-12-22 21:21:33 UTC) #4
Greg K
https://codereview.chromium.org/1532423003/diff/100001/content/browser/browser_main_loop.cc File content/browser/browser_main_loop.cc (left): https://codereview.chromium.org/1532423003/diff/100001/content/browser/browser_main_loop.cc#oldcode1038 content/browser/browser_main_loop.cc:1038: ZygoteHostImpl::GetInstance()->TearDownAfterLastChild(); On 2015/12/22 21:21:33, mdempsky wrote: > You might ...
4 years, 11 months ago (2016-01-05 21:42:13 UTC) #9
mdempsky
LGTM for content/browser/zygote_host https://codereview.chromium.org/1532423003/diff/100001/content/browser/zygote_host/zygote_communication_linux.cc File content/browser/zygote_host/zygote_communication_linux.cc (right): https://codereview.chromium.org/1532423003/diff/100001/content/browser/zygote_host/zygote_communication_linux.cc#newcode1 content/browser/zygote_host/zygote_communication_linux.cc:1: // Copyright 2015 The Chromium Authors. ...
4 years, 11 months ago (2016-01-05 22:41:57 UTC) #10
Greg K
mseaborn@chromium.org: Please review changes in nacl thestig@chromium.org: Please review changes in chome/ avi@chromium.org: Please review ...
4 years, 11 months ago (2016-01-06 18:20:41 UTC) #12
Avi (use Gerrit)
Mostly IWYU failures. https://codereview.chromium.org/1532423003/diff/260001/content/browser/zygote_host/zygote_communication_linux.cc File content/browser/zygote_host/zygote_communication_linux.cc (right): https://codereview.chromium.org/1532423003/diff/260001/content/browser/zygote_host/zygote_communication_linux.cc#newcode46 content/browser/zygote_host/zygote_communication_linux.cc:46: if (memcmp(buf, expect_msg, expect_len) != 0) ...
4 years, 11 months ago (2016-01-06 19:07:56 UTC) #13
Lei Zhang
On 2016/01/06 18:20:41, Greg Kerr wrote: > mailto:thestig@chromium.org: Please review changes in > chome/ chrome/ ...
4 years, 11 months ago (2016-01-06 19:23:46 UTC) #14
Greg K
https://codereview.chromium.org/1532423003/diff/260001/content/browser/zygote_host/zygote_communication_linux.cc File content/browser/zygote_host/zygote_communication_linux.cc (right): https://codereview.chromium.org/1532423003/diff/260001/content/browser/zygote_host/zygote_communication_linux.cc#newcode46 content/browser/zygote_host/zygote_communication_linux.cc:46: if (memcmp(buf, expect_msg, expect_len) != 0) On 2016/01/06 19:07:55, ...
4 years, 11 months ago (2016-01-06 22:24:21 UTC) #15
Avi (use Gerrit)
:) LGTM
4 years, 11 months ago (2016-01-07 01:23:40 UTC) #16
Mark Seaborn
https://codereview.chromium.org/1532423003/diff/280001/components/nacl/browser/nacl_process_host.cc File components/nacl/browser/nacl_process_host.cc (right): https://codereview.chromium.org/1532423003/diff/280001/components/nacl/browser/nacl_process_host.cc#newcode186 components/nacl/browser/nacl_process_host.cc:186: static content::ZygoteHandle zygote; Does this mean the zygote process ...
4 years, 11 months ago (2016-01-11 22:42:39 UTC) #19
mdempsky
https://codereview.chromium.org/1532423003/diff/280001/components/nacl/browser/nacl_process_host.cc File components/nacl/browser/nacl_process_host.cc (right): https://codereview.chromium.org/1532423003/diff/280001/components/nacl/browser/nacl_process_host.cc#newcode186 components/nacl/browser/nacl_process_host.cc:186: static content::ZygoteHandle zygote; On 2016/01/11 22:42:39, Mark Seaborn wrote: ...
4 years, 11 months ago (2016-01-11 22:50:28 UTC) #20
Greg K
Hi all, I had to make additional changes to ensure that the zygotes are loaded ...
4 years, 11 months ago (2016-01-15 18:23:00 UTC) #24
Lei Zhang
On 2016/01/15 18:23:00, Greg Kerr wrote: > Can all the reviewers take a look at ...
4 years, 11 months ago (2016-01-15 19:55:48 UTC) #25
Avi (use Gerrit)
still lgtm
4 years, 11 months ago (2016-01-15 19:57:14 UTC) #26
mdempsky
lgtm with nits https://codereview.chromium.org/1532423003/diff/360001/components/nacl/browser/nacl_process_host.cc File components/nacl/browser/nacl_process_host.cc (right): https://codereview.chromium.org/1532423003/diff/360001/components/nacl/browser/nacl_process_host.cc#newcode160 components/nacl/browser/nacl_process_host.cc:160: content::ZygoteHandle zygote; Google C++ style guide ...
4 years, 11 months ago (2016-01-15 20:29:42 UTC) #27
mdempsky
(Don't forget to send "Done" emails after uploading new patch sets that respond to feedback ...
4 years, 11 months ago (2016-01-16 05:24:26 UTC) #28
Greg K
https://codereview.chromium.org/1532423003/diff/360001/components/nacl/browser/nacl_process_host.cc File components/nacl/browser/nacl_process_host.cc (right): https://codereview.chromium.org/1532423003/diff/360001/components/nacl/browser/nacl_process_host.cc#newcode160 components/nacl/browser/nacl_process_host.cc:160: content::ZygoteHandle zygote; On 2016/01/15 20:29:41, mdempsky wrote: > Google ...
4 years, 11 months ago (2016-01-19 19:34:19 UTC) #29
mdempsky
lgtm for zygote OWNERS avi: Can you double check that the content/public changes still LGTY?
4 years, 11 months ago (2016-01-19 19:39:31 UTC) #30
Avi (use Gerrit)
still lgtm
4 years, 11 months ago (2016-01-19 19:42:41 UTC) #31
Mark Seaborn
https://codereview.chromium.org/1532423003/diff/400001/components/nacl/browser/nacl_process_host.h File components/nacl/browser/nacl_process_host.h (right): https://codereview.chromium.org/1532423003/diff/400001/components/nacl/browser/nacl_process_host.h#newcode96 components/nacl/browser/nacl_process_host.h:96: #if defined(OS_POSIX) && !defined(OS_ANDROID) && !defined(OS_MACOSX) NaCl isn't enabled ...
4 years, 11 months ago (2016-01-19 21:06:43 UTC) #32
mdempsky
https://codereview.chromium.org/1532423003/diff/400001/content/browser/child_process_launcher.cc File content/browser/child_process_launcher.cc (right): https://codereview.chromium.org/1532423003/diff/400001/content/browser/child_process_launcher.cc#newcode208 content/browser/child_process_launcher.cc:208: if (*zygote_handle == nullptr) { On 2016/01/19 21:06:43, Mark ...
4 years, 11 months ago (2016-01-19 21:26:43 UTC) #33
Mark Seaborn
On 2016/01/19 21:26:43, mdempsky wrote: > https://codereview.chromium.org/1532423003/diff/400001/content/browser/child_process_launcher.cc > File content/browser/child_process_launcher.cc (right): > > https://codereview.chromium.org/1532423003/diff/400001/content/browser/child_process_launcher.cc#newcode208 > ...
4 years, 11 months ago (2016-01-19 22:16:38 UTC) #34
Greg K
https://codereview.chromium.org/1532423003/diff/400001/components/nacl/browser/nacl_process_host.h File components/nacl/browser/nacl_process_host.h (right): https://codereview.chromium.org/1532423003/diff/400001/components/nacl/browser/nacl_process_host.h#newcode96 components/nacl/browser/nacl_process_host.h:96: #if defined(OS_POSIX) && !defined(OS_ANDROID) && !defined(OS_MACOSX) On 2016/01/19 21:06:43, ...
4 years, 11 months ago (2016-01-19 22:20:16 UTC) #35
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1532423003/440001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1532423003/440001
4 years, 11 months ago (2016-01-20 20:09:11 UTC) #42
commit-bot: I haz the power
Committed patchset #15 (id:440001)
4 years, 11 months ago (2016-01-20 21:11:41 UTC) #44
commit-bot: I haz the power
Patchset 15 (id:??) landed as https://crrev.com/3c1e16b490255119b6f70f94d1716645e897b185 Cr-Commit-Position: refs/heads/master@{#370488}
4 years, 11 months ago (2016-01-20 21:12:45 UTC) #46
Greg K
A revert of this CL (patchset #15 id:440001) has been created in https://codereview.chromium.org/1617213002/ by kerrnel@chromium.org. ...
4 years, 11 months ago (2016-01-21 20:26:46 UTC) #47
Greg K
Matthew, will you please look at the delta for this most recent patch set? It ...
4 years, 11 months ago (2016-01-22 18:00:17 UTC) #51
mdempsky
lgtm lgtm
4 years, 11 months ago (2016-01-22 18:46:47 UTC) #52
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1532423003/500001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1532423003/500001
4 years, 11 months ago (2016-01-22 21:10:34 UTC) #55
commit-bot: I haz the power
Committed patchset #16 (id:500001)
4 years, 11 months ago (2016-01-22 21:16:24 UTC) #57
commit-bot: I haz the power
Patchset 16 (id:??) landed as https://crrev.com/afd49a83be5da2df6667a2afd14239d7783aff52 Cr-Commit-Position: refs/heads/master@{#371042}
4 years, 11 months ago (2016-01-22 21:17:14 UTC) #59
Greg K
A revert of this CL (patchset #16 id:500001) has been created in https://codereview.chromium.org/1640123005/ by kerrnel@chromium.org. ...
4 years, 10 months ago (2016-01-28 19:19:02 UTC) #60
Lei Zhang
On 2016/01/28 19:19:02, Greg K wrote: > A revert of this CL (patchset #16 id:500001) ...
3 years, 7 months ago (2017-04-27 22:57:33 UTC) #61
Greg K
jamescook@ just posted a CL to delete them as well: https://codereview.chromium.org/2848603003/ Is this is the ...
3 years, 7 months ago (2017-04-27 22:59:14 UTC) #62
Lei Zhang
3 years, 7 months ago (2017-04-27 23:00:08 UTC) #63
Message was sent while issue was closed.
On 2017/04/27 22:59:14, Greg K wrote:
> jamescook@ just posted a CL to delete them as well:
> https://codereview.chromium.org/2848603003/
> 
> Is this is the same issue?

Yes. Wow. How did we notice it at the same time? :)

Powered by Google App Engine
This is Rietveld 408576698