mirror of
https://git.h3cjp.net/H3cJP/yuzu.git
synced 2024-12-16 15:55:30 +00:00
Merge pull request #2983 from lioncash/fallthrough
gl_shader_decompiler/vk_shader_decompiler: Resolve implicit fallthrough cases
This commit is contained in:
commit
7ecf9f7228
|
@ -2314,10 +2314,13 @@ public:
|
|||
switch (index) {
|
||||
case Tegra::Shader::Pred::NeverExecute:
|
||||
target = "false";
|
||||
break;
|
||||
case Tegra::Shader::Pred::UnusedIndex:
|
||||
target = "true";
|
||||
break;
|
||||
default:
|
||||
target = decomp.GetPredicate(index);
|
||||
break;
|
||||
}
|
||||
} else if (const auto flag = std::get_if<InternalFlagNode>(&*cc)) {
|
||||
target = decomp.GetInternalFlag(flag->GetFlag());
|
||||
|
|
|
@ -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<InternalFlagNode>(&*cc)) {
|
||||
target = decomp.internal_flags.at(static_cast<u32>(flag->GetFlag()));
|
||||
|
|
Loading…
Reference in a new issue