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

Unified Diff: cc/debug/micro_benchmark.cc

Issue 67563002: cc: Plumbing for impl thread micro benchmarks (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: speculative fix Created 7 years, 1 month 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 | « cc/debug/micro_benchmark.h ('k') | cc/debug/micro_benchmark_controller.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/debug/micro_benchmark.cc
diff --git a/cc/debug/micro_benchmark.cc b/cc/debug/micro_benchmark.cc
index 1742e7f3d6258f98321cad7034145117f078ab74..464d0cb625dd0ba40ff0774948e98f826613ae5e 100644
--- a/cc/debug/micro_benchmark.cc
+++ b/cc/debug/micro_benchmark.cc
@@ -5,13 +5,18 @@
#include "cc/debug/micro_benchmark.h"
#include "base/callback.h"
+#include "base/logging.h"
#include "base/memory/scoped_ptr.h"
+#include "base/message_loop/message_loop_proxy.h"
#include "base/values.h"
+#include "cc/debug/micro_benchmark_impl.h"
namespace cc {
MicroBenchmark::MicroBenchmark(const DoneCallback& callback)
- : callback_(callback), is_done_(false) {}
+ : callback_(callback),
+ is_done_(false),
+ processed_for_benchmark_impl_(false) {}
MicroBenchmark::~MicroBenchmark() {}
@@ -30,4 +35,20 @@ void MicroBenchmark::RunOnLayer(Layer* layer) {}
void MicroBenchmark::RunOnLayer(PictureLayer* layer) {}
+bool MicroBenchmark::ProcessedForBenchmarkImpl() const {
+ return processed_for_benchmark_impl_;
+}
+
+scoped_ptr<MicroBenchmarkImpl> MicroBenchmark::GetBenchmarkImpl(
+ scoped_refptr<base::MessageLoopProxy> origin_loop) {
+ DCHECK(!processed_for_benchmark_impl_);
+ processed_for_benchmark_impl_ = true;
+ return CreateBenchmarkImpl(origin_loop);
+}
+
+scoped_ptr<MicroBenchmarkImpl> MicroBenchmark::CreateBenchmarkImpl(
+ scoped_refptr<base::MessageLoopProxy> origin_loop) {
+ return make_scoped_ptr<MicroBenchmarkImpl>(NULL);
+}
+
} // namespace cc
« no previous file with comments | « cc/debug/micro_benchmark.h ('k') | cc/debug/micro_benchmark_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698