mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-03-21 18:01:15 +00:00
Do not unconditionally remove labels from blocks.
Labels can be shared between multiple flow-control instructions, so use the label's used counter to determine when to remove the label. This was causing problems with the jump threading.
This commit is contained in:
parent
c79620f04c
commit
ab73a267cd
1 changed files with 2 additions and 1 deletions
|
@ -1108,7 +1108,8 @@ remove_dead_blocks (sblock_t *blocks)
|
|||
label = s->opa->o.label;
|
||||
else if (!strncmp (s->opcode, "<IF", 3))
|
||||
label = s->opb->o.label;
|
||||
remove_label_from_dest (label);
|
||||
if (label && !--label->used)
|
||||
remove_label_from_dest (label);
|
||||
did_something = 1;
|
||||
|
||||
sblock->next = sb->next;
|
||||
|
|
Loading…
Reference in a new issue