diff options
author | DJ Delorie <dj@redhat.com> | 2011-04-19 16:37:11 -0400 |
---|---|---|
committer | DJ Delorie <dj@gcc.gnu.org> | 2011-04-19 16:37:11 -0400 |
commit | f067961248ea104024f8b313ae39b3b95af1f8b5 (patch) | |
tree | 97515e749f5b4fd7edaa9e6f32c6622c08a7a6fa /gcc/config/m32c/m32c.c | |
parent | 32257ddc4e61bfc4f43dff011313744fecc3fbe1 (diff) | |
download | gcc-f067961248ea104024f8b313ae39b3b95af1f8b5.zip gcc-f067961248ea104024f8b313ae39b3b95af1f8b5.tar.gz gcc-f067961248ea104024f8b313ae39b3b95af1f8b5.tar.bz2 |
m32c.c (m32c_emit_epilogue): Don't try to push registers if we already know there aren't any.
* config/m32c/m32c.c (m32c_emit_epilogue): Don't try to push
registers if we already know there aren't any.
(m32c_emit_epilogue): Don't emit a barrier here.
(m32c_emit_eh_epilogue): Likewise.
* config/m32c/blkmov.md (movstr): Don't fail on wrong-type
operands at expand time.
* config/m32c/m32c.h (WCHAR_TYPE_SIZE): Change to 4 to match "long
int" wchar type.
(REG_CLASS_CONTENTS, reg_class, REG_CLASS_NAMES): Remove
duplicates. Provide aliases instead.
* config/m32c/prologue.md (eh_return): Emit a barrier here.
(eh_epilogue): Add a "(return)" here as a hint to other parts of
the compiler.
From-SVN: r172735
Diffstat (limited to 'gcc/config/m32c/m32c.c')
-rw-r--r-- | gcc/config/m32c/m32c.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/gcc/config/m32c/m32c.c b/gcc/config/m32c/m32c.c index 055f34e..c603770 100644 --- a/gcc/config/m32c/m32c.c +++ b/gcc/config/m32c/m32c.c @@ -4485,11 +4485,14 @@ m32c_emit_prologue (void) void m32c_emit_epilogue (void) { + int popm_count = m32c_pushm_popm (PP_justcount); + /* This just emits a comment into the .s file for debugging. */ - if (m32c_pushm_popm (PP_justcount) > 0 || cfun->machine->is_interrupt) + if (popm_count > 0 || cfun->machine->is_interrupt) emit_insn (gen_epilogue_start ()); - m32c_pushm_popm (PP_popm); + if (popm_count > 0) + m32c_pushm_popm (PP_popm); if (cfun->machine->is_interrupt) { @@ -4546,7 +4549,6 @@ m32c_emit_epilogue (void) emit_jump_insn (gen_epilogue_exitd_16 ()); else emit_jump_insn (gen_epilogue_exitd_24 ()); - emit_barrier (); } void @@ -4558,7 +4560,6 @@ m32c_emit_eh_epilogue (rtx ret_addr) assembler, so punt to libgcc. */ emit_jump_insn (gen_eh_epilogue (ret_addr, cfun->machine->eh_stack_adjust)); /* emit_clobber (gen_rtx_REG (HImode, R0L_REGNO)); */ - emit_barrier (); } /* Indicate which flags must be properly set for a given conditional. */ |