From 6947bf8e44409babf6c551f00c8135edd74ca19d Mon Sep 17 00:00:00 2001 From: Lioncash Date: Tue, 15 Oct 2019 19:40:42 -0400 Subject: vk_shader_decompiler: Resolve fallthrough within ExprDecompiler's ExprCondCode operator() This would previously result in NeverExecute and UnusedIndex being treated as regular predicates. --- src/video_core/renderer_vulkan/vk_shader_decompiler.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/video_core/renderer_vulkan') diff --git a/src/video_core/renderer_vulkan/vk_shader_decompiler.cpp b/src/video_core/renderer_vulkan/vk_shader_decompiler.cpp index 8bcd04221..4fb1ca372 100644 --- a/src/video_core/renderer_vulkan/vk_shader_decompiler.cpp +++ b/src/video_core/renderer_vulkan/vk_shader_decompiler.cpp @@ -1682,10 +1682,13 @@ public: switch (index) { case Tegra::Shader::Pred::NeverExecute: target = decomp.v_false; + break; case Tegra::Shader::Pred::UnusedIndex: target = decomp.v_true; + break; default: target = decomp.predicates.at(index); + break; } } else if (const auto flag = std::get_if(&*cc)) { target = decomp.internal_flags.at(static_cast(flag->GetFlag())); -- cgit v1.2.3