diff options
author | vmpstr@chromium.org <vmpstr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-12 01:30:29 +0000 |
---|---|---|
committer | vmpstr@chromium.org <vmpstr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-12 01:30:29 +0000 |
commit | 666d7cffc8025696c6743889fcd4c9bb2980ba70 (patch) | |
tree | 3372cd68db769e6ec1649998d17ff697feadb577 /cc/layers | |
parent | d31c53449787ba09aaea6251d9ac878669218817 (diff) | |
download | chromium_src-666d7cffc8025696c6743889fcd4c9bb2980ba70.zip chromium_src-666d7cffc8025696c6743889fcd4c9bb2980ba70.tar.gz chromium_src-666d7cffc8025696c6743889fcd4c9bb2980ba70.tar.bz2 |
cc: Add MicroBenchmarkController plumbing.
This patch adds the necessary plumbing for micro benchmark controller.
The plan is as follows:
- MicroBenchmarkController will live on LayerTreeHost
- The schedule functionality will be exposed to
gpu benchmarking extension
- Javascript bindings will allow external code to schedule certain
benchmarks (specified by name) to be run right after Layer::Update.
R=enne@chromium.org,nduca@chromium.org
Review URL: https://codereview.chromium.org/26593002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@228299 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/layers')
-rw-r--r-- | cc/layers/layer.cc | 4 | ||||
-rw-r--r-- | cc/layers/layer.h | 3 |
2 files changed, 7 insertions, 0 deletions
diff --git a/cc/layers/layer.cc b/cc/layers/layer.cc index 5a9f859..15de223 100644 --- a/cc/layers/layer.cc +++ b/cc/layers/layer.cc @@ -1086,4 +1086,8 @@ void Layer::RemoveFromClipTree() { clip_parent_ = NULL; } +void Layer::RunMicroBenchmark(MicroBenchmark* benchmark) { + benchmark->RunOnLayer(this); +} + } // namespace cc diff --git a/cc/layers/layer.h b/cc/layers/layer.h index 1f8c8ac..6f391ac 100644 --- a/cc/layers/layer.h +++ b/cc/layers/layer.h @@ -16,6 +16,7 @@ #include "cc/base/cc_export.h" #include "cc/base/region.h" #include "cc/base/scoped_ptr_vector.h" +#include "cc/debug/micro_benchmark.h" #include "cc/layers/compositing_reasons.h" #include "cc/layers/draw_properties.h" #include "cc/layers/layer_lists.h" @@ -425,6 +426,8 @@ class CC_EXPORT Layer : public base::RefCounted<Layer>, return num_dependents_need_push_properties_ > 0; } + virtual void RunMicroBenchmark(MicroBenchmark* benchmark); + protected: friend class LayerImpl; friend class TreeSynchronizer; |