Commit 506f8a9597e20a305af945cf268f70ed810677ac

Charlie Lao 2025-05-08T17:03:30

Vulkan: Fix incorrect shaderWrite to shaderWrite detection There is an optimization we added in https://chromium-review.googlesource.com/c/angle/angle/+/5719258 that avoids inserting WAW barrier in between two back to back shaderWrite to the buffer, unless it is app introduced barrier via glMemoryBarrier call (i.e, it is app's responsibility to issue such WAW barrier instead of ANGLE). There is a bug in that logic that if there is a vertex read in between two shaderWrite, we will incorrectly treat it like two shaderWrites. That caused we skipped WAR before the second shaderWrite. This CL fix the logic by also looking at read access on the buffer. Bug: angleproject:350994515 Bug: angleproject:416573908 Change-Id: I5bbbeff4d7222a644d1c994bffda7fd9ea292c17 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6526949 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Charlie Lao <cclao@google.com> Reviewed-by: Yuxin Hu <yuxinhu@google.com>