aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Sandiford <rsandifo@redhat.com>2004-07-15 19:28:22 +0000
committerRichard Sandiford <rsandifo@gcc.gnu.org>2004-07-15 19:28:22 +0000
commit4c467d411382344a2a754f4d247f9b3226b3486f (patch)
tree741a6d989999af5fc6bc63b0c38f703fd1e548e6 /gcc
parentc5a419530e095f316911d63e6c2eb0008b10d160 (diff)
downloadgcc-4c467d411382344a2a754f4d247f9b3226b3486f.zip
gcc-4c467d411382344a2a754f4d247f9b3226b3486f.tar.gz
gcc-4c467d411382344a2a754f4d247f9b3226b3486f.tar.bz2
mips.c (mips_adjust_insn_length): Fix handling of calls in mips16 code.
* config/mips/mips.c (mips_adjust_insn_length): Fix handling of calls in mips16 code. From-SVN: r84772
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/config/mips/mips.c4
2 files changed, 6 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index cd45d8a..c19e996 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,10 @@
2004-07-15 Richard Sandiford <rsandifo@redhat.com>
+ * config/mips/mips.c (mips_adjust_insn_length): Fix handling of
+ calls in mips16 code.
+
+2004-07-15 Richard Sandiford <rsandifo@redhat.com>
+
* config/mips/mips.md: In the mips16 li/neg splitter, use SImode for
the destination of the li as well as for the neg.
diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c
index 70c4680..679416c 100644
--- a/gcc/config/mips/mips.c
+++ b/gcc/config/mips/mips.c
@@ -8969,9 +8969,7 @@ mips_adjust_insn_length (rtx insn, int length)
/* A unconditional jump has an unfilled delay slot if it is not part
of a sequence. A conditional jump normally has a delay slot, but
does not on MIPS16. */
- if (simplejump_p (insn)
- || (!TARGET_MIPS16 && (GET_CODE (insn) == JUMP_INSN
- || GET_CODE (insn) == CALL_INSN)))
+ if (CALL_P (insn) || (TARGET_MIPS16 ? simplejump_p (insn) : JUMP_P (insn)))
length += 4;
/* See how many nops might be needed to avoid hardware hazards. */