Index: components/startup_metric_utils/browser/startup_metric_utils.cc |
diff --git a/components/startup_metric_utils/browser/startup_metric_utils.cc b/components/startup_metric_utils/browser/startup_metric_utils.cc |
index f1ad613d5df94bc95887beaafc255f963664c4c6..c0c9f459ad40c047ea1015b4fcd5b4c83e05ba5a 100644 |
--- a/components/startup_metric_utils/browser/startup_metric_utils.cc |
+++ b/components/startup_metric_utils/browser/startup_metric_utils.cc |
@@ -769,6 +769,29 @@ void RecordFirstWebContentsMainNavigationFinished( |
g_process_creation_ticks.Get(), ticks); |
} |
+void RecordBrowserViewFirstPaint(const base::TimeTicks& ticks) { |
+ static bool is_first_call = true; |
+ if (!is_first_call || ticks.is_null()) |
+ return; |
+ is_first_call = false; |
Peter Kasting
2017/03/24 22:39:18
It seems like the only reason we need these guards
gab
2017/03/27 15:21:43
Not sure it makes sense to test this outside an in
themblsha
2017/03/31 14:32:31
We generally try test Yandex-specific histograms a
gab
2017/04/03 16:18:25
Okay then I would argue for a single browser test
|
+ |
+ UMA_HISTOGRAM_WITH_TEMPERATURE(UMA_HISTOGRAM_LONG_TIMES_100, |
+ "Startup.BrowserView.FirstPaint", |
+ ticks - g_process_creation_ticks.Get()); |
+} |
+ |
+void RecordBrowserViewFirstPaintCompositingEnded(const base::TimeTicks& ticks) { |
+ static bool is_first_call = true; |
+ if (!is_first_call || ticks.is_null()) |
+ return; |
+ is_first_call = false; |
+ |
+ UMA_HISTOGRAM_WITH_TEMPERATURE( |
gab
2017/03/27 15:21:43
Use UMA_HISTOGRAM_AND_TRACE_WITH_TEMPERATURE.
The
themblsha
2017/03/31 14:32:32
Done: https://bugs.chromium.org/p/chromium/issues/
|
+ UMA_HISTOGRAM_LONG_TIMES_100, |
+ "Startup.BrowserView.FirstPaint.CompositingEnded", |
+ ticks - g_process_creation_ticks.Get()); |
+} |
+ |
base::TimeTicks MainEntryPointTicks() { |
return g_browser_main_entry_point_ticks.Get(); |
} |