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

Unified Diff: trunk/src/gpu/command_buffer/service/texture_definition.cc

Issue 209853004: Revert 258122 "gpu: Allow fences to check whether a flush has oc..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 9 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 | « trunk/src/gpu/command_buffer/service/mailbox_synchronizer.cc ('k') | trunk/src/ui/gl/gl_context.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/gpu/command_buffer/service/texture_definition.cc
===================================================================
--- trunk/src/gpu/command_buffer/service/texture_definition.cc (revision 258964)
+++ trunk/src/gpu/command_buffer/service/texture_definition.cc (working copy)
@@ -278,8 +278,12 @@
void NativeImageBuffer::DidWrite(gfx::GLImage* client) {
base::AutoLock lock(lock_);
- // Sharing semantics require the client to flush in order to make changes
- // visible to other clients.
+ // TODO(sievers): crbug.com/352419
+ // This is super-risky. We need to somehow find out about when the current
+ // context gets flushed, so that we will only ever wait on the write fence
+ // (esp. from another context) if it was flushed and is guaranteed to clear.
+ // On the other hand, proactively flushing here is not feasible in terms
+ // of perf when there are multiple draw calls per frame.
write_fence_.reset(gfx::GLFence::CreateWithoutFlush());
write_client_ = client;
for (std::list<ClientInfo>::iterator it = client_infos_.begin();
« no previous file with comments | « trunk/src/gpu/command_buffer/service/mailbox_synchronizer.cc ('k') | trunk/src/ui/gl/gl_context.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698