cc: Make layer updating optional in BeginMainFrame
commit51d1575b2df2fc681299c84e415cc078677b95e4
authorskyostil <skyostil@chromium.org>
Wed, 12 Aug 2015 12:00:07 +0000 (12 05:00 -0700)
committerCommit bot <commit-bot@chromium.org>
Wed, 12 Aug 2015 12:00:51 +0000 (12 12:00 +0000)
tree881db86c384e81312dd6762aceb71eee6356231a
parentc24635036139d941db318145b96fda64aeeda02b
cc: Make layer updating optional in BeginMainFrame

If no-one has requested a layer update, either by calling
Proxy::SetNeedsUpdateLayers() or Proxy::SetNeedsCommit(), skip computing
the layer update in BeginMainFrame. This reduces the static overhead of
a BeginMainFrame/Commit operation when the layer tree doesn't change.

This change improves efficiency, for example, when a page has a
requestAnimationFrame callback which does not modify the DOM.

BUG=490465
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel

Review URL: https://codereview.chromium.org/1255863004

Cr-Commit-Position: refs/heads/master@{#343004}
cc/test/fake_layer_tree_host.h
cc/test/layer_tree_test.cc
cc/trees/layer_tree_host.cc
cc/trees/layer_tree_host.h
cc/trees/layer_tree_host_unittest_proxy.cc
cc/trees/thread_proxy.cc
cc/trees/thread_proxy.h
content/renderer/gpu/render_widget_compositor.cc
content/renderer/gpu/render_widget_compositor.h