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

Unified Diff: chrome/browser/chrome_browser_main.cc

Issue 888923004: Temporary commit to evaluate perf impact of prototype CPU profiler (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkcr
Patch Set: address comments Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/chrome_browser_main.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_browser_main.cc
diff --git a/chrome/browser/chrome_browser_main.cc b/chrome/browser/chrome_browser_main.cc
index e6c765f6576668a44210cf492ac3e598b4115425..b2c2e24ab9e0c0825d7d86f896b9a0a7d19b638d 100644
--- a/chrome/browser/chrome_browser_main.cc
+++ b/chrome/browser/chrome_browser_main.cc
@@ -996,6 +996,8 @@ int ChromeBrowserMainParts::PreCreateThreadsImpl() {
// IOThread's initialization which happens in BrowserProcess:PreCreateThreads.
SetupMetricsAndFieldTrials();
+ cpu_profiler_.Initialize(nullptr);
+
// ChromeOS needs ResourceBundle::InitSharedInstance to be called before this.
browser_process_->PreCreateThreads();
@@ -1650,6 +1652,8 @@ void ChromeBrowserMainParts::PostMainMessageLoopRun() {
NOTREACHED();
#else
+ cpu_profiler_.Stop();
+
// Start watching for jank during shutdown. It gets disarmed when
// |shutdown_watcher_| object is destructed.
metrics::MetricsService::SetExecutionPhase(
« no previous file with comments | « chrome/browser/chrome_browser_main.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698