sh.c (output_branch): Support for insn with lenght attr 12 & 16 which represents cond branches...

* config/sh/sh.c (output_branch): Support for insn with lenght
attr 12 & 16 which represents cond branches outside +-4096 range.

From-SVN: r42835
This commit is contained in:
Igor Shevlyakov 2001-06-03 22:17:11 +00:00 committed by Alexandre Oliva
parent 9d4d725bb8
commit 667c49250f
2 changed files with 23 additions and 6 deletions

View File

@ -1,3 +1,8 @@
2001-06-03 Igor Shevlyakov <igor@windriver.com>
* config/sh/sh.c (output_branch): Support for insn with lenght
attr 12 & 16 which represents cond branches outside +-4096 range.
2001-06-03 Alexandre Oliva <aoliva@redhat.com>
* config/sh/lib1funcs.asm (ic_invalidate): Align the

View File

@ -799,8 +799,12 @@ output_branch (logic, insn, operands)
rtx insn;
rtx *operands;
{
switch (get_attr_length (insn))
int len = get_attr_length (insn);
switch (len)
{
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
@ -823,16 +827,24 @@ 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);
output_asm_insn ("bra\t%l0", &op0);
fprintf (asm_out_file, "\tnop\n");
ASM_OUTPUT_INTERNAL_LABEL(asm_out_file, "LF", 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);
return "";
}