diff options
author | Richard Sandiford <rsandifo@linux.vnet.ibm.com> | 2014-01-14 14:45:07 +0000 |
---|---|---|
committer | Richard Sandiford <rsandifo@gcc.gnu.org> | 2014-01-14 14:45:07 +0000 |
commit | db93087523a4696d5231798e4371ad189cd309df (patch) | |
tree | 81c0565010b0383de9606b0d2bb85240b2a5e69d /gcc | |
parent | a0e35eb02c65ca7aa1c429a1032a463129623669 (diff) | |
download | gcc-db93087523a4696d5231798e4371ad189cd309df.zip gcc-db93087523a4696d5231798e4371ad189cd309df.tar.gz gcc-db93087523a4696d5231798e4371ad189cd309df.tar.bz2 |
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
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/jump.c | 10 |
2 files changed, 15 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d9d1949..ae8d412 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +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. */ |