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

Unified Diff: third_party/WebKit/Source/platform/scheduler/renderer/renderer_scheduler_impl.cc

Issue 2954473002: Record accuracy of expected queueing time metric. (Closed)
Patch Set: Set trace ID in test. Created 3 years, 6 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
Index: third_party/WebKit/Source/platform/scheduler/renderer/renderer_scheduler_impl.cc
diff --git a/third_party/WebKit/Source/platform/scheduler/renderer/renderer_scheduler_impl.cc b/third_party/WebKit/Source/platform/scheduler/renderer/renderer_scheduler_impl.cc
index 37ec1fbd3bc120f48bf957d4aead6abe82368bbc..9c88b3baa5c98834785f80d3a7427633605064cf 100644
--- a/third_party/WebKit/Source/platform/scheduler/renderer/renderer_scheduler_impl.cc
+++ b/third_party/WebKit/Source/platform/scheduler/renderer/renderer_scheduler_impl.cc
@@ -850,6 +850,10 @@ void RendererSchedulerImpl::DidHandleInputEventOnMainThread(
}
}
+base::TimeDelta RendererSchedulerImpl::MostRecentExpectedQueueingTime() {
+ return GetMainThreadOnly().most_recent_expected_queueing_time;
+}
+
bool RendererSchedulerImpl::IsHighPriorityWorkAnticipated() {
helper_.CheckOnValidThread();
if (helper_.IsShutdown())
@@ -2029,6 +2033,8 @@ void RendererSchedulerImpl::RemoveTaskTimeObserver(
void RendererSchedulerImpl::OnQueueingTimeForWindowEstimated(
base::TimeDelta queueing_time,
base::TimeTicks window_start_time) {
+ GetMainThreadOnly().most_recent_expected_queueing_time = queueing_time;
+
if (GetMainThreadOnly().has_navigated) {
if (GetMainThreadOnly().max_queueing_time < queueing_time) {
if (!GetMainThreadOnly().max_queueing_time_metric) {

Powered by Google App Engine
This is Rietveld 408576698