Commit e4f4044d authored by Sunny Sachanandani's avatar Sunny Sachanandani Committed by Commit Bot

gpu: Reset OrderingBarrier state when recreating get buffer.

If the get buffer is destroyed say in SetAggressivelyFreeResources, the
next OrderingBarrier call after recreating the get buffer will see the
old value for last_barrier_put_offset_. CommandBufferProxyImpl uses this
to set the put_offset_changed parameter for OrderingBarrier. If the new
put_offset_ matches last_barrier_put_offset_ exactly the OrderingBarrier
becomes a nop. That can cause contexts to run out of order causing
all sorts of rendering glitches.

R=jbauman
BUG=715997

Cq-Include-Trybots: master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel
Change-Id: Ie1e511e22a3e2f3b0e71ea872bbd690925725be9
Reviewed-on: https://chromium-review.googlesource.com/495369Reviewed-by: default avatarJohn Bauman <jbauman@chromium.org>
Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
Cr-Commit-Position: refs/heads/master@{#469217}
parent 8904a238
......@@ -410,6 +410,7 @@ void CommandBufferProxyImpl::SetGetBuffer(int32_t shm_id) {
Send(new GpuCommandBufferMsg_SetGetBuffer(route_id_, shm_id));
last_put_offset_ = -1;
last_barrier_put_offset_ = -1;
}
scoped_refptr<gpu::Buffer> CommandBufferProxyImpl::CreateTransferBuffer(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment