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

Unified Diff: components/startup_metric_utils/startup_metric_utils.cc

Issue 1421293005: Move new Startup.FirstWebContents.* stats to Startup.FirstWebContents.*2. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ab2_moar_betta_metrics
Patch Set: Created 5 years, 2 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 | « components/startup_metric_utils/startup_metric_utils.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/startup_metric_utils/startup_metric_utils.cc
diff --git a/components/startup_metric_utils/startup_metric_utils.cc b/components/startup_metric_utils/startup_metric_utils.cc
index a526d79842a4619fbabc23d8cfbafa93a6112a70..5e243c5eed8add0e9ba234ddc318e6ed0836e13c 100644
--- a/components/startup_metric_utils/startup_metric_utils.cc
+++ b/components/startup_metric_utils/startup_metric_utils.cc
@@ -428,10 +428,23 @@ void RecordFirstWebContentsMainFrameLoad(const base::Time& time) {
return;
UMA_HISTOGRAM_AND_TRACE_WITH_STARTUP_TEMPERATURE(
- UMA_HISTOGRAM_LONG_TIMES_100, "Startup.FirstWebContents.MainFrameLoad",
+ UMA_HISTOGRAM_LONG_TIMES_100, "Startup.FirstWebContents.MainFrameLoad2",
g_process_creation_time.Get(), time);
}
+void RecordDeprecatedFirstWebContentsMainFrameLoad(const base::Time& time) {
+ static bool is_first_call = true;
+ if (!is_first_call || time.is_null())
+ return;
+ is_first_call = false;
+ if (WasNonBrowserUIDisplayed() || g_process_creation_time.Get().is_null())
+ return;
+
+ UMA_HISTOGRAM_WITH_STARTUP_TEMPERATURE(
+ UMA_HISTOGRAM_LONG_TIMES_100, "Startup.FirstWebContents.MainFrameLoad",
+ time - g_process_creation_time.Get());
+}
+
void RecordFirstWebContentsNonEmptyPaint(const base::Time& time) {
static bool is_first_call = true;
if (!is_first_call || time.is_null())
@@ -441,10 +454,23 @@ void RecordFirstWebContentsNonEmptyPaint(const base::Time& time) {
return;
UMA_HISTOGRAM_AND_TRACE_WITH_STARTUP_TEMPERATURE(
- UMA_HISTOGRAM_LONG_TIMES_100, "Startup.FirstWebContents.NonEmptyPaint",
+ UMA_HISTOGRAM_LONG_TIMES_100, "Startup.FirstWebContents.NonEmptyPaint2",
g_process_creation_time.Get(), time);
}
+void RecordDeprecatedFirstWebContentsNonEmptyPaint(const base::Time& time) {
+ static bool is_first_call = true;
+ if (!is_first_call || time.is_null())
+ return;
+ is_first_call = false;
+ if (WasNonBrowserUIDisplayed() || g_process_creation_time.Get().is_null())
+ return;
+
+ UMA_HISTOGRAM_WITH_STARTUP_TEMPERATURE(
+ UMA_HISTOGRAM_LONG_TIMES_100, "Startup.FirstWebContents.NonEmptyPaint",
+ time - g_process_creation_time.Get());
+}
+
void RecordFirstWebContentsMainNavigationStart(const base::Time& time) {
static bool is_first_call = true;
if (!is_first_call || time.is_null())
« no previous file with comments | « components/startup_metric_utils/startup_metric_utils.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698