diff options
author | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1998-03-05 22:05:51 +0000 |
---|---|---|
committer | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 1998-03-05 22:05:51 +0000 |
commit | 943e16d804bbdca9cc278ac2024b2687a964bf1a (patch) | |
tree | 00eaa7957d065f847be209659ab8054a2b40303b /gcc/jump.c | |
parent | 54e73e2c2037227f1312e688a901708029dbfcf5 (diff) | |
download | gcc-943e16d804bbdca9cc278ac2024b2687a964bf1a.tar.gz |
* jump.c (jump_optimize): Call mark_jump_label also for deleted
insns.
(mark_jump_label): Don't increment ref counts for deleted insns.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@18420 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/jump.c')
-rw-r--r-- | gcc/jump.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/gcc/jump.c b/gcc/jump.c index c5710f2ec3f..4b7a5f4d035 100644 --- a/gcc/jump.c +++ b/gcc/jump.c @@ -212,11 +212,10 @@ jump_optimize (f, cross_jump, noop_moves, after_regscan) also make a chain of all returns. */ for (insn = f; insn; insn = NEXT_INSN (insn)) - if (GET_RTX_CLASS (GET_CODE (insn)) == 'i' - && ! INSN_DELETED_P (insn)) + if (GET_RTX_CLASS (GET_CODE (insn)) == 'i') { mark_jump_label (PATTERN (insn), insn, cross_jump); - if (GET_CODE (insn) == JUMP_INSN) + if (! INSN_DELETED_P (insn) && GET_CODE (insn) == JUMP_INSN) { if (JUMP_LABEL (insn) != 0 && simplejump_p (insn)) { @@ -3380,7 +3379,8 @@ mark_jump_label (x, insn, cross_jump) } XEXP (x, 0) = label; - ++LABEL_NUSES (label); + if (! insn || ! INSN_DELETED_P (insn)) + ++LABEL_NUSES (label); if (insn) { @@ -3417,12 +3417,13 @@ mark_jump_label (x, insn, cross_jump) ADDR_DIFF_VEC. Don't set the JUMP_LABEL of a vector. */ case ADDR_VEC: case ADDR_DIFF_VEC: - { - int eltnum = code == ADDR_DIFF_VEC ? 1 : 0; + if (! INSN_DELETED_P (insn)) + { + int eltnum = code == ADDR_DIFF_VEC ? 1 : 0; - for (i = 0; i < XVECLEN (x, eltnum); i++) - mark_jump_label (XVECEXP (x, eltnum, i), NULL_RTX, cross_jump); - } + for (i = 0; i < XVECLEN (x, eltnum); i++) + mark_jump_label (XVECEXP (x, eltnum, i), NULL_RTX, cross_jump); + } return; default: |