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

Unified Diff: cc/debug/micro_benchmark.h

Issue 300963004: cc: Add message passing mechanism to micro benchmarking. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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
« no previous file with comments | « no previous file | cc/debug/micro_benchmark.cc » ('j') | cc/debug/micro_benchmark_controller.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/debug/micro_benchmark.h
diff --git a/cc/debug/micro_benchmark.h b/cc/debug/micro_benchmark.h
index f179fb9544d200ef30373fc4be88b1836c9469ea..c773933c861ff0c6c5de671c30b289fa59021999 100644
--- a/cc/debug/micro_benchmark.h
+++ b/cc/debug/micro_benchmark.h
@@ -24,15 +24,18 @@ class CC_EXPORT MicroBenchmark {
public:
typedef base::Callback<void(scoped_ptr<base::Value>)> DoneCallback;
- explicit MicroBenchmark(const DoneCallback& callback);
+ explicit MicroBenchmark(const DoneCallback& callback, int id);
vmpstr 2014/05/28 21:16:25 Since this id isn't used by any particular benchma
ernstm 2014/05/28 21:51:55 Done. The id is now set in ScheduleRun, after the
virtual ~MicroBenchmark();
bool IsDone() const;
virtual void DidUpdateLayers(LayerTreeHost* host);
+ int id() const { return id_; }
virtual void RunOnLayer(Layer* layer);
virtual void RunOnLayer(PictureLayer* layer);
+ virtual bool SendMessage(scoped_ptr<base::Value> value);
+
bool ProcessedForBenchmarkImpl() const;
scoped_ptr<MicroBenchmarkImpl> GetBenchmarkImpl(
scoped_refptr<base::MessageLoopProxy> origin_loop);
@@ -47,6 +50,7 @@ class CC_EXPORT MicroBenchmark {
DoneCallback callback_;
bool is_done_;
bool processed_for_benchmark_impl_;
+ int id_;
};
} // namespace cc
« no previous file with comments | « no previous file | cc/debug/micro_benchmark.cc » ('j') | cc/debug/micro_benchmark_controller.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698