pa.c (output_call): Only use sr4 for long interspace calls if call binds local and generating non...

* pa.c (output_call): Only use sr4 for long interspace calls if
	call binds local and generating non PIC code.
	(attr_length_call): Adjust length calculation for above.

From-SVN: r154528
This commit is contained in:
John David Anglin 2009-11-25 00:35:16 +00:00 committed by John David Anglin
parent 329033b5f5
commit eebe23c290
2 changed files with 12 additions and 6 deletions

View File

@ -1,3 +1,9 @@
2009-11-24 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
* pa.c (output_call): Only use sr4 for long interspace calls if
call binds local and generating non PIC code.
(attr_length_call): Adjust length calculation for above.
2009-11-24 Wolfgang Gellerich <gellerich@de.ibm.com>
* config/s390/s390.md: Added agen condition to operand

View File

@ -7437,7 +7437,7 @@ attr_length_call (rtx insn, int sibcall)
{
length += 20;
if (!TARGET_PA_20 && !TARGET_NO_SPACE_REGS && flag_pic)
if (!TARGET_PA_20 && !TARGET_NO_SPACE_REGS && (!local_call || flag_pic))
length += 8;
}
@ -7457,7 +7457,7 @@ attr_length_call (rtx insn, int sibcall)
if (!sibcall)
length += 8;
if (!TARGET_NO_SPACE_REGS && flag_pic)
if (!TARGET_NO_SPACE_REGS && (!local_call || flag_pic))
length += 8;
}
}
@ -7654,7 +7654,7 @@ output_call (rtx insn, rtx call_dest, int sibcall)
if (!sibcall && !TARGET_PA_20)
{
output_asm_insn ("{bl|b,l} .+8,%%r2", xoperands);
if (TARGET_NO_SPACE_REGS)
if (TARGET_NO_SPACE_REGS || (local_call && !flag_pic))
output_asm_insn ("addi 8,%%r2,%%r2", xoperands);
else
output_asm_insn ("addi 16,%%r2,%%r2", xoperands);
@ -7679,20 +7679,20 @@ output_call (rtx insn, rtx call_dest, int sibcall)
}
else
{
if (!TARGET_NO_SPACE_REGS && flag_pic)
if (!TARGET_NO_SPACE_REGS && (!local_call || flag_pic))
output_asm_insn ("ldsid (%%r1),%%r31\n\tmtsp %%r31,%%sr0",
xoperands);
if (sibcall)
{
if (TARGET_NO_SPACE_REGS || !flag_pic)
if (TARGET_NO_SPACE_REGS || (local_call && !flag_pic))
output_asm_insn ("be 0(%%sr4,%%r1)", xoperands);
else
output_asm_insn ("be 0(%%sr0,%%r1)", xoperands);
}
else
{
if (TARGET_NO_SPACE_REGS || !flag_pic)
if (TARGET_NO_SPACE_REGS || (local_call && !flag_pic))
output_asm_insn ("ble 0(%%sr4,%%r1)", xoperands);
else
output_asm_insn ("ble 0(%%sr0,%%r1)", xoperands);