1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2024-12-03 22:24:13 +01:00

[dxvk] Relax compute shader barriers for read-only storage buffers

This commit is contained in:
Philip Rebohle 2018-12-13 22:42:36 +01:00
parent a0de90861c
commit 0bc2498570
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99

View File

@ -3123,6 +3123,7 @@ namespace dxvk {
switch (binding.type) {
case VK_DESCRIPTOR_TYPE_STORAGE_BUFFER:
case VK_DESCRIPTOR_TYPE_STORAGE_BUFFER_DYNAMIC:
if (binding.access & VK_ACCESS_SHADER_WRITE_BIT)
access.set(DxvkAccess::Write);
/* fall through */
@ -3133,6 +3134,7 @@ namespace dxvk {
break;
case VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER:
if (binding.access & VK_ACCESS_SHADER_WRITE_BIT)
access.set(DxvkAccess::Write);
/* fall through */
@ -3142,6 +3144,7 @@ namespace dxvk {
break;
case VK_DESCRIPTOR_TYPE_STORAGE_IMAGE:
if (binding.access & VK_ACCESS_SHADER_WRITE_BIT)
access.set(DxvkAccess::Write);
/* fall through */
@ -3177,6 +3180,7 @@ namespace dxvk {
switch (binding.type) {
case VK_DESCRIPTOR_TYPE_STORAGE_BUFFER:
case VK_DESCRIPTOR_TYPE_STORAGE_BUFFER_DYNAMIC:
if (binding.access & VK_ACCESS_SHADER_WRITE_BIT)
access |= VK_ACCESS_SHADER_WRITE_BIT;
/* fall through */
@ -3190,6 +3194,7 @@ namespace dxvk {
break;
case VK_DESCRIPTOR_TYPE_STORAGE_TEXEL_BUFFER:
if (binding.access & VK_ACCESS_SHADER_WRITE_BIT)
access |= VK_ACCESS_SHADER_WRITE_BIT;
/* fall through */
@ -3202,6 +3207,7 @@ namespace dxvk {
break;
case VK_DESCRIPTOR_TYPE_STORAGE_IMAGE:
if (binding.access & VK_ACCESS_SHADER_WRITE_BIT)
access |= VK_ACCESS_SHADER_WRITE_BIT;
/* fall through */