aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorDJ Delorie <dj@redhat.com>2008-02-20 16:31:56 -0500
committerDJ Delorie <dj@gcc.gnu.org>2008-02-20 16:31:56 -0500
commit6d4a896759d342850e6a9ba2639d2159df79e5ea (patch)
tree0ee021354c0daf8ebe5be89f1b26785548c1c688 /gcc
parenta214518f7f23a6f5d2f81b4a4824c68488831c48 (diff)
downloadgcc-6d4a896759d342850e6a9ba2639d2159df79e5ea.zip
gcc-6d4a896759d342850e6a9ba2639d2159df79e5ea.tar.gz
gcc-6d4a896759d342850e6a9ba2639d2159df79e5ea.tar.bz2
h8300.md (insv): Force source operand to be a register.
* config/h8300/h8300.md (insv): Force source operand to be a register. * config/h8300/h8300.c (h8300_expand_epilogue): Emit return insn as a jump, not as a plain insn. From-SVN: r132498
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog7
-rw-r--r--gcc/config/h8300/h8300.c2
-rw-r--r--gcc/config/h8300/h8300.md3
3 files changed, 11 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d17b56c..fc400d2 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,10 @@
+2008-02-20 DJ Delorie <dj@redhat.com>
+
+ * config/h8300/h8300.md (insv): Force source operand to be a register.
+
+ * config/h8300/h8300.c (h8300_expand_epilogue): Emit return insn
+ as a jump, not as a plain insn.
+
2008-02-20 Seongbae Park <seongbae.park@gmail.com>
* doc/invoke.texi (Warning Options): Add new option
diff --git a/gcc/config/h8300/h8300.c b/gcc/config/h8300/h8300.c
index 96b6311..f90bd41 100644
--- a/gcc/config/h8300/h8300.c
+++ b/gcc/config/h8300/h8300.c
@@ -930,7 +930,7 @@ h8300_expand_epilogue (void)
}
if (!returned_p)
- emit_insn (gen_rtx_RETURN (VOIDmode));
+ emit_jump_insn (gen_rtx_RETURN (VOIDmode));
}
/* Return nonzero if the current function is an interrupt
diff --git a/gcc/config/h8300/h8300.md b/gcc/config/h8300/h8300.md
index 08a8d2e..9b6c0aa 100644
--- a/gcc/config/h8300/h8300.md
+++ b/gcc/config/h8300/h8300.md
@@ -3282,6 +3282,9 @@
if (GET_CODE (operands[0]) == MEM
|| GET_CODE (operands[3]) == MEM)
FAIL;
+
+ if (GET_CODE (operands[3]) != REG)
+ operands[3] = force_reg (HImode, operands[3]);
}")
(define_insn ""