aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1995-09-15 18:24:09 -0400
committerRichard Kenner <kenner@gcc.gnu.org>1995-09-15 18:24:09 -0400
commit970c9acebff0668e05d591ba34184f68b32c21e8 (patch)
tree9ebb96c4c9a12bfad9d01234232da4739230e936 /gcc
parent7a9b75b671b25d03d7afe4c116f0f1b8d89ca90a (diff)
downloadgcc-970c9acebff0668e05d591ba34184f68b32c21e8.zip
gcc-970c9acebff0668e05d591ba34184f68b32c21e8.tar.gz
gcc-970c9acebff0668e05d591ba34184f68b32c21e8.tar.bz2
(insert): Set cse_jumps_altered when inserting a LABEL_REF.
From-SVN: r10366
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cse.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/gcc/cse.c b/gcc/cse.c
index cba56fe..863a338 100644
--- a/gcc/cse.c
+++ b/gcc/cse.c
@@ -1287,6 +1287,14 @@ insert (x, classp, hash, mode)
SET_HARD_REG_BIT (hard_regs_in_table, i);
}
+ /* If X is a label, show we are altering jumps. We don't KNOW
+ we are, but we might be putting it into a insn which would
+ then need a new REG_LABEL note. Be conservative and say
+ we alter jumps here; we usually will in this case anyway. */
+ if (GET_CODE (x) == LABEL_REF
+ || (GET_CODE (x) == CONST && GET_CODE (XEXP (x, 0)) == PLUS
+ && GET_CODE (XEXP (XEXP (x, 0), 0)) == LABEL_REF))
+ cse_jumps_altered = 1;
/* Put an element for X into the right hash bucket. */