mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2024-12-27 18:16:23 +00:00
recompiler: emit a label right after s_branch to prevent dead code interferrence (#1785)
This commit is contained in:
parent
f93677b953
commit
876445faf1
|
@ -80,6 +80,8 @@ void CFG::EmitLabels() {
|
|||
if (inst.IsUnconditionalBranch()) {
|
||||
const u32 target = inst.BranchTarget(pc);
|
||||
AddLabel(target);
|
||||
// Emit this label so that the block ends with s_branch instruction
|
||||
AddLabel(pc + inst.length);
|
||||
} else if (inst.IsConditionalBranch()) {
|
||||
const u32 true_label = inst.BranchTarget(pc);
|
||||
const u32 false_label = pc + inst.length;
|
||||
|
|
Loading…
Reference in a new issue