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

Issue 10510013: GPU: Adding sync points for cross-channel synchronization (Closed)

Created:
8 years, 6 months ago by piman
Modified:
8 years, 6 months ago
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam, apatrick_chromium, jochen+watch-content_chromium.org, jonathan.backer
Visibility:
Public.

Description

GPU: Adding sync points for cross-channel synchronization Theory of operation: command buffer 1 calls InsertSyncPoint, it returns an ID, command buffer 2 calls WaitSyncPoint on that ID (even if on another channel). The wait is pipelined. InsertSyncPoint is handled on the IO thread in the GPU process, so it's presumably fast, but its effect is ordered wrt the other messages. Some benefits of the approach: - once InsertSyncPoint returns the ID, the sync point is already enqueued to be eventually retired, so it makes it very hard to cause deadlocks by incorrect operation on the client side. - the wait will return if the command buffer that inserted the sync point gets destroyed. This primitive should be enough for guaranteeing browser->renderer ordering. Additional changes are needed to safely handle renderer->browser ordering (especially in case of buggy/malicious renderer). BUG=112299 TEST=manual (With other patches) Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=140653

Patch Set 1 #

Patch Set 2 : protected destructor #

Total comments: 16

Patch Set 3 : review comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+339 lines, -7 lines) Patch
M content/common/gpu/client/command_buffer_proxy_impl.h View 1 chunk +2 lines, -0 lines 0 comments Download
M content/common/gpu/client/command_buffer_proxy_impl.cc View 1 chunk +10 lines, -0 lines 0 comments Download
M content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.h View 1 chunk +3 lines, -0 lines 0 comments Download
M content/common/gpu/client/webgraphicscontext3d_command_buffer_impl.cc View 1 chunk +11 lines, -0 lines 0 comments Download
M content/common/gpu/gpu_channel.cc View 1 2 3 chunks +107 lines, -1 line 0 comments Download
M content/common/gpu/gpu_channel_manager.h View 3 chunks +4 lines, -0 lines 0 comments Download
M content/common/gpu/gpu_channel_manager.cc View 2 chunks +3 lines, -1 line 0 comments Download
M content/common/gpu/gpu_command_buffer_stub.h View 1 2 4 chunks +12 lines, -4 lines 0 comments Download
M content/common/gpu/gpu_command_buffer_stub.cc View 4 chunks +36 lines, -0 lines 0 comments Download
M content/common/gpu/gpu_messages.h View 1 chunk +17 lines, -0 lines 0 comments Download
A content/common/gpu/sync_point_manager.h View 1 2 1 chunk +54 lines, -0 lines 0 comments Download
A content/common/gpu/sync_point_manager.cc View 1 2 1 chunk +56 lines, -0 lines 0 comments Download
M content/content_common.gypi View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M gpu/ipc/command_buffer_proxy.h View 1 2 1 chunk +11 lines, -0 lines 0 comments Download
M ppapi/proxy/ppapi_command_buffer_proxy.h View 1 chunk +2 lines, -0 lines 0 comments Download
M ppapi/proxy/ppapi_command_buffer_proxy.cc View 2 chunks +9 lines, -1 line 0 comments Download

Messages

Total messages: 12 (0 generated)
piman
apatrick: please review brettw: OWNERS for content/content_common.gypi and ppapi/proxy
8 years, 6 months ago (2012-06-05 02:20:33 UTC) #1
Fady Samuel
On 2012/06/05 02:20:33, piman wrote: > apatrick: please review > brettw: OWNERS for content/content_common.gypi and ...
8 years, 6 months ago (2012-06-05 02:26:20 UTC) #2
piman
On Mon, Jun 4, 2012 at 7:26 PM, <fsamuel@chromium.org> wrote: > On 2012/06/05 02:20:33, piman ...
8 years, 6 months ago (2012-06-05 02:43:07 UTC) #3
piman
cc: backer FYI
8 years, 6 months ago (2012-06-05 02:46:11 UTC) #4
Fady Samuel
Thinking out loud (please don't let this block this cl): Would a timeout solve this ...
8 years, 6 months ago (2012-06-05 04:20:23 UTC) #5
piman
On Mon, Jun 4, 2012 at 9:20 PM, Fady Samuel <fsamuel@chromium.org> wrote: > Thinking out ...
8 years, 6 months ago (2012-06-05 06:46:41 UTC) #6
apatrick_chromium
I gave this three passes and I think it's right. Just nits. https://chromiumcodereview.appspot.com/10510013/diff/7001/content/common/gpu/gpu_channel.cc File content/common/gpu/gpu_channel.cc ...
8 years, 6 months ago (2012-06-05 18:44:15 UTC) #7
brettw
LGTM (I assume you needed an owners review from me, this is rubberstamp based on ...
8 years, 6 months ago (2012-06-05 19:38:57 UTC) #8
piman
https://chromiumcodereview.appspot.com/10510013/diff/7001/content/common/gpu/gpu_channel.cc File content/common/gpu/gpu_channel.cc (right): https://chromiumcodereview.appspot.com/10510013/diff/7001/content/common/gpu/gpu_channel.cc#newcode24 content/common/gpu/gpu_channel.cc:24: #include "ipc/ipc_channel.h" On 2012/06/05 18:44:15, apatrick_chromium wrote: > and ...
8 years, 6 months ago (2012-06-05 20:09:50 UTC) #9
apatrick_chromium
lgtm
8 years, 6 months ago (2012-06-05 22:16:02 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/piman@chromium.org/10510013/15001
8 years, 6 months ago (2012-06-05 22:22:45 UTC) #11
commit-bot: I haz the power
8 years, 6 months ago (2012-06-05 23:35:26 UTC) #12
Change committed as 140653

Powered by Google App Engine
This is Rietveld 408576698