Commit 2f3e6cc07c1c4e107ac7d74d2b5380f81422902d

Charlie Lao 2021-12-13T17:40:18

Vulkan: Remove mShadowBuffer from BufferVk class. The shadow buffer was initially designed to avoid synchronization in glMapBuffer call while buffer itself is still busy. There are many optimization done inside BufferVk::mapImpl that try to avoid wait for GPU as much as we can by distinguish GPU write versus read, by detecting map call read/write intention by checking access bit, and finally by allocating a staging buffer to return a CPU friendly copy of data to caller. This shadow buffer implementation also have known bugs that are not keeping data in sync. With all these optimization added after initial mShadowBuffer implementation, I believe we do not have a good reason to still keep mShadowBuffer. And this has been disabled for months in main branch. This CL removes this code path completely which makes code a lot simpler. Bug: b/208323792 Change-Id: Ie5999e38b6120a371ec2e969f196e4754ebd0f8d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3313333 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: mohan maiya <m.maiya@samsung.com> Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Charlie Lao <cclao@google.com>