public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: chenglulu <chenglulu@loongson.cn>
To: Xi Ruoyao <xry111@xry111.site>, gcc-patches@gcc.gnu.org
Cc: i@xen0n.name, xuchenghua@loongson.cn
Subject: Re: [pushed][PATCH v2] LoongArch: Add code generation support for call36 function calls.
Date: Mon, 20 Nov 2023 10:07:50 +0800	[thread overview]
Message-ID: <ccd2a78d-ed40-8de6-5b89-4aba1dc9c2cc@loongson.cn> (raw)
In-Reply-To: <07e40cebfbae358acb97c17b2390d202a3124cfc.camel@xry111.site>


在 2023/11/20 上午9:51, Xi Ruoyao 写道:
> On Mon, 2023-11-20 at 09:09 +0800, chenglulu wrote:
>> 在 2023/11/19 上午1:24, Xi Ruoyao 写道:
>>> On Sat, 2023-11-18 at 16:16 +0800, chenglulu wrote:
>>>> Pushed to r14-5567.
>>>>
>>>> 在 2023/11/16 下午3:27, Lulu Cheng 写道:
>>>>> When compiling with '-mcmodel=medium', the function call is made through
>>>>> 'pcaddu18i+jirl' if binutils supports call36, otherwise the
>>>>> native implementation 'pcalau12i+jirl' is used.
>>>>>
>>>>> gcc/ChangeLog:
>>>>>
>>>>> 	* config.in: Regenerate.
>>>>> 	* config/loongarch/loongarch-opts.h (HAVE_AS_SUPPORT_CALL36): Define macro.
>>>>> 	* config/loongarch/loongarch.cc (loongarch_legitimize_call_address):
>>>>> 	If binutils supports call36, the function call is not split over expand.
>>>>> 	* config/loongarch/loongarch.md: Add call36 generation code.
>>>>> 	* config/loongarch/predicates.md: Likewise.
>>>>> 	* configure: Regenerate.
>>>>> 	* configure.ac: Check whether binutils supports call36.
>>> With this change I get some test failures with "old" Binutils 2.41:
>>>
>>> FAIL: gcc.target/loongarch/func-call-medium-1.c scan-assembler test:.*la.global\\t.*g\\n\\tjirl
>>> FAIL: gcc.target/loongarch/func-call-medium-1.c scan-assembler test1:.*la.global\\t.*f\\n\\tjirl
>>> FAIL: gcc.target/loongarch/func-call-medium-1.c scan-assembler test2:.*la.local\\t.*l\\n\\tjirl
>>> FAIL: gcc.target/loongarch/func-call-medium-2.c scan-assembler test:.*la.global\\t.*g\\n\\tjirl
>>> FAIL: gcc.target/loongarch/func-call-medium-2.c scan-assembler test1:.*la.local\\t.*f\\n\\tjirl
>>> FAIL: gcc.target/loongarch/func-call-medium-2.c scan-assembler test2:.*la.local\\t.*l\\n\\tjirl
>>> FAIL: gcc.target/loongarch/func-call-medium-3.c scan-assembler test2:.*la.local\\t.*l\\n\\tjirl
>>> FAIL: gcc.target/loongarch/func-call-medium-4.c scan-assembler test1:.*la.local\\t.*f\\n\\tjirl
>>> FAIL: gcc.target/loongarch/func-call-medium-4.c scan-assembler test2:.*la.local\\t.*l\\n\\tjirl
>>>
>>> Some strange thing is happening: with -mexplicit-relocs=auto or always I
>>> get pcalau12i + jirl as expected, but with -mexplicit-relocs=none I get
>>> "pcaddu18i $r1,%call36(g)" and jirl.  This seems irony (!).
>>>
>> Thank you for the revision.
> Then I'll push
> https://gcc.gnu.org/pipermail/gcc-patches/2023-November/637153.html if
> this is an approval?
>
OK. Thanks.


      reply	other threads:[~2023-11-20  2:08 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-16  7:27 [PATCH " Lulu Cheng
2023-11-18  8:16 ` [pushed][PATCH " chenglulu
2023-11-18 17:24   ` Xi Ruoyao
2023-11-20  1:09     ` chenglulu
2023-11-20  1:51       ` Xi Ruoyao
2023-11-20  2:07         ` chenglulu [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ccd2a78d-ed40-8de6-5b89-4aba1dc9c2cc@loongson.cn \
    --to=chenglulu@loongson.cn \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=i@xen0n.name \
    --cc=xry111@xry111.site \
    --cc=xuchenghua@loongson.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).