Commit db930875 by Richard Sandiford Committed by Richard Sandiford

jump.c (redirect_jump_2): Remove REG_CROSSING_JUMP notes when converting a…

jump.c (redirect_jump_2): Remove REG_CROSSING_JUMP notes when converting a conditional jump into a...

gcc/
	* jump.c (redirect_jump_2): Remove REG_CROSSING_JUMP notes when
	converting a conditional jump into a conditional return.

From-SVN: r206600
parent a0e35eb0
2014-01-14 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
* jump.c (redirect_jump_2): Remove REG_CROSSING_JUMP notes when
converting a conditional jump into a conditional return.
2014-01-14 Richard Biener <rguenther@suse.de>
PR tree-optimization/58921
......
......@@ -1580,6 +1580,16 @@ redirect_jump_2 (rtx jump, rtx olabel, rtx nlabel, int delete_unused,
}
}
/* Handle the case where we had a conditional crossing jump to a return
label and are now changing it into a direct conditional return.
The jump is no longer crossing in that case. */
if (ANY_RETURN_P (nlabel))
{
note = find_reg_note (jump, REG_CROSSING_JUMP, NULL_RTX);
if (note)
remove_note (jump, note);
}
if (!ANY_RETURN_P (olabel)
&& --LABEL_NUSES (olabel) == 0 && delete_unused > 0
/* Undefined labels will remain outside the insn stream. */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment