Index: cc/trees/thread_proxy.cc |
diff --git a/cc/trees/thread_proxy.cc b/cc/trees/thread_proxy.cc |
index 07264322ef8285c6c0b9b57803cea3e90e7df709..89768502c62016d66162f267c3e92f92801b71c0 100644 |
--- a/cc/trees/thread_proxy.cc |
+++ b/cc/trees/thread_proxy.cc |
@@ -14,6 +14,7 @@ |
#include "cc/base/swap_promise.h" |
#include "cc/debug/benchmark_instrumentation.h" |
#include "cc/debug/devtools_instrumentation.h" |
+#include "cc/debug/performance_draw_timing_counter.h" |
#include "cc/input/input_handler.h" |
#include "cc/output/context_provider.h" |
#include "cc/output/output_surface.h" |
@@ -720,6 +721,10 @@ void ThreadProxy::ScheduledActionSendBeginMainFrame() { |
impl().layer_tree_host_impl->memory_allocation_priority_cutoff(); |
begin_main_frame_state->evicted_ui_resources = |
impl().layer_tree_host_impl->EvictedUIResourcesExist(); |
+ begin_main_frame_state->draw_info = |
+ impl().layer_tree_host_impl->draw_counter()->getDrawTimingCounts(); |
+ impl().layer_tree_host_impl->draw_counter()->clearEvents(); |
+ |
Proxy::MainThreadTaskRunner()->PostTask( |
FROM_HERE, |
base::Bind(&ThreadProxy::BeginMainFrame, |
@@ -791,6 +796,8 @@ void ThreadProxy::BeginMainFrame( |
layer_tree_host()->ApplyScrollAndScale(*begin_main_frame_state->scroll_info); |
+ layer_tree_host()->RecordDrawTiming(*begin_main_frame_state->draw_info); |
+ |
layer_tree_host()->WillBeginMainFrame(); |
layer_tree_host()->UpdateClientAnimations( |