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

Side by Side Diff: content/browser/browser_main_loop.cc

Issue 2530043002: Set process phases in the StackSamplingProfiler. (Closed)
Patch Set: rebased Created 4 years 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #include "content/browser/browser_main_loop.h" 5 #include "content/browser/browser_main_loop.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 800 matching lines...) Expand 10 before | Expand all | Expand 10 after
811 #if !defined(GOOGLE_CHROME_BUILD) || defined(OS_ANDROID) 811 #if !defined(GOOGLE_CHROME_BUILD) || defined(OS_ANDROID)
812 // Single-process is an unsupported and not fully tested mode, so 812 // Single-process is an unsupported and not fully tested mode, so
813 // don't enable it for official Chrome builds (except on Android). 813 // don't enable it for official Chrome builds (except on Android).
814 if (parsed_command_line_.HasSwitch(switches::kSingleProcess)) 814 if (parsed_command_line_.HasSwitch(switches::kSingleProcess))
815 RenderProcessHost::SetRunRendererInProcess(true); 815 RenderProcessHost::SetRunRendererInProcess(true);
816 #endif 816 #endif
817 817
818 return result_code_; 818 return result_code_;
819 } 819 }
820 820
821 void BrowserMainLoop::PreShutdown() {
822 parts_->PreShutdown();
823 }
824
825 void BrowserMainLoop::PostShutdown() {
826 parts_->PostShutdown();
827 }
828
821 void BrowserMainLoop::CreateStartupTasks() { 829 void BrowserMainLoop::CreateStartupTasks() {
822 TRACE_EVENT0("startup", "BrowserMainLoop::CreateStartupTasks"); 830 TRACE_EVENT0("startup", "BrowserMainLoop::CreateStartupTasks");
823 831
824 // First time through, we really want to create all the tasks 832 // First time through, we really want to create all the tasks
825 if (!startup_task_runner_.get()) { 833 if (!startup_task_runner_.get()) {
826 #if defined(OS_ANDROID) 834 #if defined(OS_ANDROID)
827 startup_task_runner_ = base::MakeUnique<StartupTaskRunner>( 835 startup_task_runner_ = base::MakeUnique<StartupTaskRunner>(
828 base::Bind(&BrowserStartupComplete), 836 base::Bind(&BrowserStartupComplete),
829 base::ThreadTaskRunnerHandle::Get()); 837 base::ThreadTaskRunnerHandle::Get());
830 #else 838 #else
(...skipping 795 matching lines...) Expand 10 before | Expand all | Expand 10 after
1626 scoped_refptr<base::SingleThreadTaskRunner> worker_task_runner = 1634 scoped_refptr<base::SingleThreadTaskRunner> worker_task_runner =
1627 audio_thread_->task_runner(); 1635 audio_thread_->task_runner();
1628 audio_manager_ = media::AudioManager::Create(std::move(audio_task_runner), 1636 audio_manager_ = media::AudioManager::Create(std::move(audio_task_runner),
1629 std::move(worker_task_runner), 1637 std::move(worker_task_runner),
1630 MediaInternals::GetInstance()); 1638 MediaInternals::GetInstance());
1631 } 1639 }
1632 CHECK(audio_manager_); 1640 CHECK(audio_manager_);
1633 } 1641 }
1634 1642
1635 } // namespace content 1643 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698