aboutsummaryrefslogtreecommitdiff
path: root/gcc/cse.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2004-02-16 01:39:54 -0800
committerRichard Henderson <rth@gcc.gnu.org>2004-02-16 01:39:54 -0800
commit9dcb4381bc1795c369bda33b6ebaf842b32b2bdc (patch)
tree880a3428df52901e36e2c1bd4561bbf71be1211d /gcc/cse.c
parent1472042a4a7a89c84f7c93df2bb92556a0014d84 (diff)
downloadgcc-9dcb4381bc1795c369bda33b6ebaf842b32b2bdc.zip
gcc-9dcb4381bc1795c369bda33b6ebaf842b32b2bdc.tar.gz
gcc-9dcb4381bc1795c369bda33b6ebaf842b32b2bdc.tar.bz2
* cse.c (cse_insn): Don't lose REG_NON_LOCAL_GOTO note.
From-SVN: r77877
Diffstat (limited to 'gcc/cse.c')
-rw-r--r--gcc/cse.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/gcc/cse.c b/gcc/cse.c
index 55fe072..4262f4d 100644
--- a/gcc/cse.c
+++ b/gcc/cse.c
@@ -5719,10 +5719,20 @@ cse_insn (rtx insn, rtx libcall_insn)
and hope for the best. */
if (n_sets == 1)
{
- rtx new = emit_jump_insn_after (gen_jump (XEXP (src, 0)), insn);
+ rtx new, note;
+ new = emit_jump_insn_after (gen_jump (XEXP (src, 0)), insn);
JUMP_LABEL (new) = XEXP (src, 0);
LABEL_NUSES (XEXP (src, 0))++;
+
+ /* Make sure to copy over REG_NON_LOCAL_GOTO. */
+ note = find_reg_note (insn, REG_NON_LOCAL_GOTO, 0);
+ if (note)
+ {
+ XEXP (note, 1) = NULL_RTX;
+ REG_NOTES (new) = note;
+ }
+
delete_insn (insn);
insn = new;