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

Unified Diff: content/common/gpu/client/context_provider_command_buffer.cc

Issue 1317533003: Revert of cc: Move worker context BindToCurrentThread/SetupLock calls out of cc::OutputSurface. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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 | « content/browser/compositor/gpu_process_transport_factory.cc ('k') | content/renderer/render_widget.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/gpu/client/context_provider_command_buffer.cc
diff --git a/content/common/gpu/client/context_provider_command_buffer.cc b/content/common/gpu/client/context_provider_command_buffer.cc
index 172b1e8720d5681ef32583a7953dbe9435d724cc..ba9f0ebfbed6a6f75196c29a7bf89da933557773 100644
--- a/content/common/gpu/client/context_provider_command_buffer.cc
+++ b/content/common/gpu/client/context_provider_command_buffer.cc
@@ -182,9 +182,7 @@
}
void ContextProviderCommandBuffer::OnLostContext() {
- // Note: no thread check here as this should not change the thread for which
- // this context is currently bound. e.g. a worker context might be unbound
- // and this should not result in it being bound to the current thread.
+ DCHECK(context_thread_checker_.CalledOnValidThread());
{
base::AutoLock lock(main_thread_lock_);
if (destroyed_)
@@ -199,9 +197,8 @@
void ContextProviderCommandBuffer::OnMemoryAllocationChanged(
const gpu::MemoryAllocation& allocation) {
- // Note: no thread check here as this should not change the thread for which
- // this context is currently bound. e.g. a worker context might be unbound
- // and this should not result in it being bound to the current thread.
+ DCHECK(context_thread_checker_.CalledOnValidThread());
+
if (memory_policy_changed_callback_.is_null())
return;
« no previous file with comments | « content/browser/compositor/gpu_process_transport_factory.cc ('k') | content/renderer/render_widget.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698