diff options
author | J"orn Rennecke <amylaar@redhat.com> | 2001-06-19 00:58:29 +0000 |
---|---|---|
committer | Joern Rennecke <amylaar@gcc.gnu.org> | 2001-06-19 01:58:29 +0100 |
commit | afbc5d8693b2f82cf772e417f6d4e2358cde5865 (patch) | |
tree | c040cdfb9b0e9957c2909dec28a637bb227a0764 | |
parent | c8b2822138be0f4c83da1cbd27cee0913a095760 (diff) | |
download | gcc-afbc5d8693b2f82cf772e417f6d4e2358cde5865.zip gcc-afbc5d8693b2f82cf772e417f6d4e2358cde5865.tar.gz gcc-afbc5d8693b2f82cf772e417f6d4e2358cde5865.tar.bz2 |
sh.c (output_branch): Delete bogus code.
* sh.c (output_branch): Delete bogus code.
* sh.c (initial_elimination_offset):
Fix FROM == RETURN_ADDRESS_POINTER_REGNUM case.
From-SVN: r43450
-rw-r--r-- | gcc/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/config/sh/sh.c | 35 |
2 files changed, 17 insertions, 25 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 13daeb5..d0e6541 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +Tue Jun 19 01:52:27 2001 J"orn Rennecke <amylaar@redhat.com> + + * sh.c (output_branch): Delete bogus code. + + * sh.c (initial_elimination_offset): + Fix FROM == RETURN_ADDRESS_POINTER_REGNUM case. + Mon Jun 18 12:50:49 2001 Jeffrey A Law (law@cygnus.com) * flow.c (find_unreachable_blocks): New function. diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c index 0c18256..8afb976 100644 --- a/gcc/config/sh/sh.c +++ b/gcc/config/sh/sh.c @@ -802,12 +802,8 @@ output_branch (logic, insn, operands) rtx insn; rtx *operands; { - int len = get_attr_length (insn); - - switch (len) + switch (get_attr_length (insn)) { - case 16: - case 12: case 6: /* This can happen if filling the delay slot has caused a forward branch to exceed its range (we could reverse it, but only @@ -830,24 +826,16 @@ output_branch (logic, insn, operands) if (final_sequence && ! INSN_ANNULLED_BRANCH_P (XVECEXP (final_sequence, 0, 0))) { - asm_fprintf (asm_out_file, "\tb%s%ss\t%LLF%d\n", - logic ? "f" : "t", + asm_fprintf (asm_out_file, "\tb%s%ss\t%LLF%d\n", logic ? "f" : "t", ASSEMBLER_DIALECT ? "/" : ".", label); print_slot (final_sequence); } else - asm_fprintf (asm_out_file, "\tb%s\t%LLF%d\n", logic ? "f" : "t", - label); + asm_fprintf (asm_out_file, "\tb%s\t%LLF%d\n", logic ? "f" : "t", label); - if (len == 6) - { - output_asm_insn ("bra\t%l0", &op0); - fprintf (asm_out_file, "\tnop\n"); - } - else - output_far_jump (insn, op0); - - ASM_OUTPUT_INTERNAL_LABEL (asm_out_file, "LF", label); + output_asm_insn ("bra\t%l0", &op0); + fprintf (asm_out_file, "\tnop\n"); + ASM_OUTPUT_INTERNAL_LABEL(asm_out_file, "LF", label); return ""; } @@ -856,6 +844,9 @@ output_branch (logic, insn, operands) case 2: return logic ? "bt%.\t%l0" : "bf%.\t%l0"; default: + /* There should be no longer branches now - that would + indicate that something has destroyed the branches set + up in machine_dependent_reorg. */ abort (); } } @@ -4555,13 +4546,7 @@ initial_elimination_offset (from, to) if (from == RETURN_ADDRESS_POINTER_REGNUM && (to == FRAME_POINTER_REGNUM || to == STACK_POINTER_REGNUM)) - { - int i, n = total_saved_regs_space; - for (i = PR_REG-1; i >= 0; i--) - if (live_regs_mask & (1 << i)) - n -= 4; - return n + total_auto_space; - } + return UNITS_PER_WORD + total_auto_space; abort (); } |