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

Unified Diff: chrome/common/startup_metric_utils.cc

Issue 14683012: Merge 198707 "Record first run startup metrics." (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1500/src/
Patch Set: Created 7 years, 7 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/common/startup_metric_utils.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/startup_metric_utils.cc
===================================================================
--- chrome/common/startup_metric_utils.cc (revision 199532)
+++ chrome/common/startup_metric_utils.cc (working copy)
@@ -65,7 +65,7 @@
return *MainEntryPointTimeInternal();
}
-void OnBrowserStartupComplete() {
+void OnBrowserStartupComplete(bool is_first_run) {
// Bail if uptime < 7 minutes, to filter out cases where Chrome may have been
// autostarted and the machine is under io pressure.
const int64 kSevenMinutesInMilliseconds =
@@ -85,9 +85,15 @@
// cases where Chrome is auto-started and IO is heavily loaded.
base::TimeDelta startup_time_from_main_entry =
base::Time::Now() - MainEntryStartTime();
- UMA_HISTOGRAM_LONG_TIMES(
- "Startup.BrowserMessageLoopStartTimeFromMainEntry",
- startup_time_from_main_entry);
+ if (is_first_run) {
+ UMA_HISTOGRAM_LONG_TIMES(
+ "Startup.BrowserMessageLoopStartTimeFromMainEntry.FirstRun",
+ startup_time_from_main_entry);
+ } else {
+ UMA_HISTOGRAM_LONG_TIMES(
+ "Startup.BrowserMessageLoopStartTimeFromMainEntry",
+ startup_time_from_main_entry);
+ }
// Create another histogram that records the exact number for use by
// performance tests.
« no previous file with comments | « chrome/common/startup_metric_utils.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698