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

Side by Side Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 1643533006: Use a single, generic, global zygote to temporarily resolve perf regressions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Represents the browser side of the browser <--> renderer communication 5 // Represents the browser side of the browser <--> renderer communication
6 // channel. There will be one RenderProcessHost per renderer process. 6 // channel. There will be one RenderProcessHost per renderer process.
7 7
8 #include "content/browser/renderer_host/render_process_host_impl.h" 8 #include "content/browser/renderer_host/render_process_host_impl.h"
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 527 matching lines...) Expand 10 before | Expand all | Expand 10 after
538 538
539 // static 539 // static
540 void RenderProcessHost::SetMaxRendererProcessCount(size_t count) { 540 void RenderProcessHost::SetMaxRendererProcessCount(size_t count) {
541 g_max_renderer_count_override = count; 541 g_max_renderer_count_override = count;
542 } 542 }
543 543
544 #if defined(OS_POSIX) && !defined(OS_ANDROID) && !defined(OS_MACOSX) 544 #if defined(OS_POSIX) && !defined(OS_ANDROID) && !defined(OS_MACOSX)
545 // static 545 // static
546 void RenderProcessHostImpl::EarlyZygoteLaunch() { 546 void RenderProcessHostImpl::EarlyZygoteLaunch() {
547 DCHECK(!g_render_zygote); 547 DCHECK(!g_render_zygote);
548 g_render_zygote = CreateZygote(); 548 g_render_zygote = GetGenericZygote();
549 // TODO(kerrnel): Investigate doing this without the ZygoteHostImpl as a 549 // TODO(kerrnel): Investigate doing this without the ZygoteHostImpl as a
550 // proxy. It is currently done this way due to concerns about race 550 // proxy. It is currently done this way due to concerns about race
551 // conditions. 551 // conditions.
552 ZygoteHostImpl::GetInstance()->SetRendererSandboxStatus( 552 ZygoteHostImpl::GetInstance()->SetRendererSandboxStatus(
553 g_render_zygote->GetSandboxStatus()); 553 g_render_zygote->GetSandboxStatus());
mdempsky 2016/01/28 23:25:40 (*GetGenericZygote())->GetSandboxStatus()
Greg K 2016/01/29 00:41:03 Done.
554 } 554 }
555 #endif // defined(OS_POSIX) && !defined(OS_ANDROID) && !defined(OS_MACOSX) 555 #endif // defined(OS_POSIX) && !defined(OS_ANDROID) && !defined(OS_MACOSX)
556 556
557 RenderProcessHostImpl::RenderProcessHostImpl( 557 RenderProcessHostImpl::RenderProcessHostImpl(
558 BrowserContext* browser_context, 558 BrowserContext* browser_context,
559 StoragePartitionImpl* storage_partition_impl, 559 StoragePartitionImpl* storage_partition_impl,
560 bool is_for_guests_only) 560 bool is_for_guests_only)
561 : fast_shutdown_started_(false), 561 : fast_shutdown_started_(false),
562 deleting_soon_(false), 562 deleting_soon_(false),
563 #ifndef NDEBUG 563 #ifndef NDEBUG
(...skipping 2224 matching lines...) Expand 10 before | Expand all | Expand 10 after
2788 void RenderProcessHostImpl::GetAudioOutputControllers( 2788 void RenderProcessHostImpl::GetAudioOutputControllers(
2789 const GetAudioOutputControllersCallback& callback) const { 2789 const GetAudioOutputControllersCallback& callback) const {
2790 audio_renderer_host()->GetOutputControllers(callback); 2790 audio_renderer_host()->GetOutputControllers(callback);
2791 } 2791 }
2792 2792
2793 BluetoothDispatcherHost* RenderProcessHostImpl::GetBluetoothDispatcherHost() { 2793 BluetoothDispatcherHost* RenderProcessHostImpl::GetBluetoothDispatcherHost() {
2794 return bluetooth_dispatcher_host_.get(); 2794 return bluetooth_dispatcher_host_.get();
2795 } 2795 }
2796 2796
2797 } // namespace content 2797 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698