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

Unified Diff: cc/thread_proxy.cc

Issue 12096112: [cc] Trace detailed tile info when --trace-all-rendered-frames (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 years, 10 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/thread_proxy.cc
diff --git a/cc/thread_proxy.cc b/cc/thread_proxy.cc
index adb9d016d020f8acb2c046493c0daf03fb706fc4..fe92817ea58a659061e98380f4953a1c5dd5043c 100644
--- a/cc/thread_proxy.cc
+++ b/cc/thread_proxy.cc
@@ -1088,6 +1088,29 @@ ThreadProxy::BeginFrameAndCommitState::~BeginFrameAndCommitState()
{
}
+scoped_ptr<base::Value> ThreadProxy::asValue() const
+{
+ scoped_ptr<base::DictionaryValue> state(new base::DictionaryValue());
+
+ CompletionEvent completion;
+ {
+ DebugScopedSetMainThreadBlocked mainThreadBlocked(
+ const_cast<ThreadProxy*>(this));
+ Proxy::implThread()->postTask(base::Bind(&ThreadProxy::asValueOnImplThread,
+ m_implThreadWeakPtr,
+ &completion,
+ state.get()));
+ completion.wait();
+ }
+ return state.PassAs<base::Value>();
+}
+
+void ThreadProxy::asValueOnImplThread(CompletionEvent* completion, base::DictionaryValue* state) const
+{
+ state->Set("layer_tree_host_impl", m_layerTreeHostImpl->asValue().release());
+ completion->signal();
+}
+
bool ThreadProxy::commitPendingForTesting()
{
DCHECK(isMainThread());
« no previous file with comments | « cc/thread_proxy.h ('k') | cc/tile.h » ('j') | content/renderer/gpu/gpu_benchmarking_extension.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698