From: John David Anglin Date: Fri, 1 Nov 2019 23:35:06 +0000 (+0000) Subject: backport: pa.c (pa_output_call): Remove 64-bit sibcall sequence. X-Git-Tag: releases/gcc-9.3.0~438 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4ce50f89f3a474a898cf1257044a80b077b6eded;p=thirdparty%2Fgcc.git backport: pa.c (pa_output_call): Remove 64-bit sibcall sequence. Backport from mainline 2019-10-03 John David Anglin * config/pa/pa.c (pa_output_call): Remove 64-bit sibcall sequence. (pa_attr_length_call): Adjust length for 64-bit plabel sequence. From-SVN: r277736 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1fb0e82b35a8..b534127d2328 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2019-11-01 John David Anglin + + Backport from mainline + 2019-10-03 John David Anglin + + * config/pa/pa.c (pa_output_call): Remove 64-bit sibcall sequence. + (pa_attr_length_call): Adjust length for 64-bit plabel sequence. + 2019-11-01 John David Anglin Backport from mainline diff --git a/gcc/config/pa/pa.c b/gcc/config/pa/pa.c index 5784fc076f5a..6d75f26e02f4 100644 --- a/gcc/config/pa/pa.c +++ b/gcc/config/pa/pa.c @@ -7856,7 +7856,7 @@ pa_attr_length_call (rtx_insn *insn, int sibcall) /* 64-bit plabel sequence. */ else if (TARGET_64BIT && !local_call) - length += sibcall ? 28 : 24; + length += 24; /* non-pic long absolute branch sequence. */ else if ((TARGET_LONG_ABS_CALL || local_call) && !flag_pic) @@ -7928,38 +7928,24 @@ pa_output_call (rtx_insn *insn, rtx call_dest, int sibcall) xoperands[0] = pa_get_deferred_plabel (call_dest); xoperands[1] = gen_label_rtx (); - /* If this isn't a sibcall, we put the load of %r27 into the - delay slot. We can't do this in a sibcall as we don't - have a second call-clobbered scratch register available. - We don't need to do anything when generating fast indirect - calls. */ - if (seq_length != 0 && !sibcall) + /* Put the load of %r27 into the delay slot. We don't need to + do anything when generating fast indirect calls. */ + if (seq_length != 0) { final_scan_insn (NEXT_INSN (insn), asm_out_file, optimize, 0, NULL); /* Now delete the delay insn. */ SET_INSN_DELETED (NEXT_INSN (insn)); - seq_length = 0; } output_asm_insn ("addil LT'%0,%%r27", xoperands); output_asm_insn ("ldd RT'%0(%%r1),%%r1", xoperands); output_asm_insn ("ldd 0(%%r1),%%r1", xoperands); - - if (sibcall) - { - output_asm_insn ("ldd 24(%%r1),%%r27", xoperands); - output_asm_insn ("ldd 16(%%r1),%%r1", xoperands); - output_asm_insn ("bve (%%r1)", xoperands); - } - else - { - output_asm_insn ("ldd 16(%%r1),%%r2", xoperands); - output_asm_insn ("bve,l (%%r2),%%r2", xoperands); - output_asm_insn ("ldd 24(%%r1),%%r27", xoperands); - seq_length = 1; - } + output_asm_insn ("ldd 16(%%r1),%%r2", xoperands); + output_asm_insn ("bve,l (%%r2),%%r2", xoperands); + output_asm_insn ("ldd 24(%%r1),%%r27", xoperands); + seq_length = 1; } else {