summaryrefslogtreecommitdiff
path: root/src/shader_recompiler/ir_opt
diff options
context:
space:
mode:
authorGravatar ameerj2022-01-28 19:00:04 -0500
committerGravatar ameerj2022-01-28 19:00:04 -0500
commit4790ba783970a9dde9d9ce6a528dd8f7edc50ae6 (patch)
tree7ed65721d3be9b2468eeee51dcc7f9550b1034df /src/shader_recompiler/ir_opt
parentMerge pull request #7784 from german77/ds5 (diff)
downloadyuzu-4790ba783970a9dde9d9ce6a528dd8f7edc50ae6.tar.gz
yuzu-4790ba783970a9dde9d9ce6a528dd8f7edc50ae6.tar.xz
yuzu-4790ba783970a9dde9d9ce6a528dd8f7edc50ae6.zip
spirv_atomic: Define U32x2 storage buffers for 64-bit storage atomics
Some drivers do not support 64-bit atomics, and fallback to atomically modifying U32x2 vectors. This change ensures that U32x2 storage vectors are defined in the spir-v shader when 64-bit atomics are used. Fixes a hang on some devices, notably Intel GPUs, when booting Pokemon Legends Arceus
Diffstat (limited to 'src/shader_recompiler/ir_opt')
-rw-r--r--src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp b/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp
index a78c469be..b6a20f904 100644
--- a/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp
+++ b/src/shader_recompiler/ir_opt/collect_shader_info_pass.cpp
@@ -688,7 +688,7 @@ void VisitUsages(Info& info, IR::Inst& inst) {
688 case IR::Opcode::StorageAtomicAnd64: 688 case IR::Opcode::StorageAtomicAnd64:
689 case IR::Opcode::StorageAtomicOr64: 689 case IR::Opcode::StorageAtomicOr64:
690 case IR::Opcode::StorageAtomicXor64: 690 case IR::Opcode::StorageAtomicXor64:
691 info.used_storage_buffer_types |= IR::Type::U64; 691 info.used_storage_buffer_types |= IR::Type::U64 | IR::Type::U32x2;
692 info.uses_int64_bit_atomics = true; 692 info.uses_int64_bit_atomics = true;
693 break; 693 break;
694 case IR::Opcode::BindlessImageAtomicIAdd32: 694 case IR::Opcode::BindlessImageAtomicIAdd32: