From: Xi Ruoyao <xry111@xry111.site>
To: chenglulu <chenglulu@loongson.cn>
Cc: gcc-patches@gcc.gnu.org, WANG Xuerui <i@xen0n.name>,
Jiajie Chen <c@jia.je>, Chenghua Xu <xuchenghua@loongson.cn>
Subject: Re: LoongArch: Backport r14-4674 "LoongArch: Delete macro definition ASM_OUTPUT_ALIGN_WITH_NOP."?
Date: Tue, 20 Feb 2024 19:54:17 +0800 [thread overview]
Message-ID: <0c35a60aa584ce78bcb58c1dd601e08ee6d6bf55.camel@xry111.site> (raw)
In-Reply-To: <f7788548-39e5-8e34-f0c7-eb615d2bfaa5@loongson.cn>
On Tue, 2024-02-20 at 19:50 +0800, chenglulu wrote:
>
> 在 2024/2/20 下午7:31, Xi Ruoyao 写道:
> > On Tue, 2024-02-20 at 19:25 +0800, Xi Ruoyao wrote:
> > > On Tue, 2024-02-20 at 10:07 +0800, chenglulu wrote:
> > >
> > > > So I think that without worrying about performance and ensuring that
> > > > there is no problem
> > > >
> > > > with binutils, I think we can make the following modifications:
> > > >
> > > > -/* "nop" instruction 54525952 (andi $r0,$r0,0) is
> > > > - used for padding. */
> > > > +/* ".align num,,4" will insert "nop"(andi $r0,$r0,0) into padding by
> > > > + default. */
> > > > #define ASM_OUTPUT_ALIGN_WITH_NOP(STREAM, LOG) \
> > > > - fprintf (STREAM, "\t.align\t%d,54525952,4\n", (LOG))
> > > > + fprintf (STREAM, "\t.align\t%d,,4\n", (LOG))
> > > >
> > > > What do you think of it?
> > > Unfortunately it will cause warnings with GAS 2.41 or earlier like
> > >
> > > t1.s:1: Warning: expected fill pattern missing
> > > t1.s:5: Warning: expected fill pattern missing
> > >
> > > And AFAIK these things may cause many test failures due to "excessive
> > > errors" if running the GCC test suite with these earlier GAS versions.
> > > Maybe we'll have to add some autoconf-based probing for the linker
> > > anyway?
> > Or just silence the warning passing "--no-warn" to the assembler but I'm
> > highly unsure if this is really a good idea :(.
> >
> I am not opposed to adding detection code, but I looked at this problem
> today
>
> and I think this change is the smallest change. I asked Meng Qinggang and he
>
> said that the warning of GAS 2.41 can be removed.
Yes, but we cannot change a released binutils-2.41 tarball and Binutils
folks don't make point releases like GCC.
--
Xi Ruoyao <xry111@xry111.site>
School of Aerospace Science and Technology, Xidian University
next prev parent reply other threads:[~2024-02-20 11:54 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-06 16:23 Xi Ruoyao
2024-02-08 16:02 ` chenglulu
2024-02-09 8:08 ` Xi Ruoyao
2024-02-20 2:07 ` chenglulu
2024-02-20 11:25 ` Xi Ruoyao
2024-02-20 11:31 ` Xi Ruoyao
2024-02-20 11:50 ` chenglulu
2024-02-20 11:54 ` Xi Ruoyao [this message]
2024-02-20 12:03 ` chenglulu
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=0c35a60aa584ce78bcb58c1dd601e08ee6d6bf55.camel@xry111.site \
--to=xry111@xry111.site \
--cc=c@jia.je \
--cc=chenglulu@loongson.cn \
--cc=gcc-patches@gcc.gnu.org \
--cc=i@xen0n.name \
--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).