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

Unified Diff: cc/debug/micro_benchmark_controller.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
Index: cc/debug/micro_benchmark_controller.h
diff --git a/cc/debug/micro_benchmark_controller.h b/cc/debug/micro_benchmark_controller.h
index 7220dc1778fa7b0cef4570699056b272fba0608d..edf2278f39652564ae241b3a6d172896cdb5b1eb 100644
--- a/cc/debug/micro_benchmark_controller.h
+++ b/cc/debug/micro_benchmark_controller.h
@@ -28,17 +28,21 @@ class CC_EXPORT MicroBenchmarkController {
void DidUpdateLayers();
- bool ScheduleRun(const std::string& micro_benchmark_name,
- scoped_ptr<base::Value> value,
- const MicroBenchmark::DoneCallback& callback);
+ int ScheduleRun(const std::string& micro_benchmark_name,
vmpstr 2014/05/28 21:16:25 Make a comment about the return value, please.
ernstm 2014/05/28 21:51:55 Done.
+ scoped_ptr<base::Value> value,
+ const MicroBenchmark::DoneCallback& callback);
+
+ bool SendMessage(int id, scoped_ptr<base::Value> value);
void ScheduleImplBenchmarks(LayerTreeHostImpl* host_impl);
private:
void CleanUpFinishedBenchmarks();
+ int GetNextIdAndIncrement();
LayerTreeHost* host_;
ScopedPtrVector<MicroBenchmark> benchmarks_;
+ int next_id_;
vmpstr 2014/05/28 21:16:25 I think we only have one controller, but maybe mak
ernstm 2014/05/28 21:51:55 Done.
scoped_refptr<base::MessageLoopProxy> main_controller_message_loop_;
DISALLOW_COPY_AND_ASSIGN(MicroBenchmarkController);

Powered by Google App Engine
This is Rietveld 408576698