public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Nick Clifton <nickc@redhat.com>
To: "Jose E. Marchesi" <jose.marchesi@oracle.com>,
	Nick Clifton via Binutils <binutils@sourceware.org>
Subject: Re: Commit: Gas: Add .nop directive.
Date: Tue, 15 Sep 2020 12:13:06 +0100	[thread overview]
Message-ID: <66993ade-f84c-5f7a-86e8-a1dd017f38b5@redhat.com> (raw)
In-Reply-To: <87bli89y63.fsf@oracle.com>

Hi Jose,


> In the same spirit, it would be awesome to be able to generate
> architecture-neutral data directives as well, for DWARF and CTF and the
> like :)

What about ".dc.b <val>" ?  Does that not work for all targets ?

>> +#define md_single_noop_insn "mov %r1,%r1"
> 
> For BPF we have this in GCC:
> 
> (define_insn "nop"
>   [(const_int 0)]
>   ""
>   "mov\t%%r0,%%r0"

> I think it would be good to settle on the same way to encode nops in
> both GCC and binutils.

Actually David Faust just posted a patch to change the instruction to "ja 0"
as this is what the kernel expects.  I have applied his patch to gas.  Maybe
gcc should be updated as well ?

Cheers
  Nick



  reply	other threads:[~2020-09-15 11:13 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-14 15:13 Nick Clifton
2020-09-14 15:27 ` Jose E. Marchesi
2020-09-15 11:13   ` Nick Clifton [this message]
2020-09-15 11:57     ` Jose E. Marchesi
2020-09-14 15:38 ` Andreas Schwab
2020-09-14 16:02   ` Nick Clifton
2020-09-30 18:18 ` Maciej W. Rozycki
     [not found] <mailman.151032.1600097231.8982.binutils@sourceware.org>
2020-09-14 16:04 ` Michael Morrell
2020-09-14 16:31   ` Nick Clifton
2020-09-15  9:53     ` Nick Clifton

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=66993ade-f84c-5f7a-86e8-a1dd017f38b5@redhat.com \
    --to=nickc@redhat.com \
    --cc=binutils@sourceware.org \
    --cc=jose.marchesi@oracle.com \
    /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).