public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Alan Modra <amodra@gmail.com>
To: Peter Bergner <bergner@vnet.ibm.com>
Cc: binutils@sourceware.org
Subject: Re: Remove E6500 insns from PPC_OPCODE_ALTIVEC2
Date: Sat, 08 Apr 2017 01:08:00 -0000	[thread overview]
Message-ID: <20170408010756.GY16711@bubble.grove.modra.org> (raw)
In-Reply-To: <9d148375-51cf-65bd-7a9f-2f6ab3f5f806@vnet.ibm.com>

On Fri, Apr 07, 2017 at 07:59:23AM -0500, Peter Bergner wrote:
> On 4/7/17 4:53 AM, Alan Modra wrote:
> > This isn't losing anything from the testsuite.  All of these insns
> > appear in testsuite/gas/ppc/e6500.s
> > 
> > opcodes/
> > 	* ppc-opc.c (powerpc_opcodes <mviwsplt, mvidsplt, lvexbx, lvepxl,
> > 	lvexhx, lvepx, lvexwx, stvexbx, stvexhx, stvexwx, lvtrx, lvtlx,
> > 	lvswx, stvfrx, stvflx, stvswx, lvsm, stvepxl, lvtrxl, stvepx,
> > 	lvtlxl, lvswxl, stvfrxl, stvflxl, stvswxl>): Enable E6500 only
> > 	vector instructions with E6500 not PPCVEC2.
> > gas/
> > 	* testsuite/gas/ppc/altivec2.s: Delete E6500 vector insns.
> > 	* testsuite/gas/ppc/altivec2.d: Adjust to suit.
> 
> Looks good to me, but I have to wonder how you noticed these, unless
> you read various PPC ISA docs in your free time? ;-)

Thanks for reviewing.  The patch came from Aaron finding an odd opcode
in traces of SPEC which objdump disassembled as stswxl, then Aaron
saying he couldn't find that in ISA 3.0 or 2.07.

Of course, even after this patch objdump still disassembles the opcode
to stswxl since we default to power9 with PPC_OPCODE_ANY, if objdump
is invoked without selected a cpu.

On another subject, I'd like your opinion on removing -[mM]htm options
from gas and the disassembler.  I think now that it was a mistake to
add them in the first place (and every other use of .sticky except for
-mall and -mraw).  I would have liked to remove -[mM]vsx too, but
"gcc -mvsx" passes on -mvsx to gas, and has done so for quite some
time.  So -mvsx looks impossible to remove without breaking gcc.
"gcc -mhtm" on the other hand, passes -mpower8 to gas, and it's been
that way since -mhtm was added to gcc.

Also, I'm intending to remove some of PPC_OPCODE_*, for instance
PPC_OPCODE_ALTIVEC2 can disappear and we then use

#define PPCVEC2 (PPC_OPCODE_POWER8 | PPC_OPCODE_E6500)
#define PPCVEC3 PPC_OPCODE_POWER9

in opcodes/ppc-opc.c which should improve gas opcode checks vs. cpu.
Dodgy gcc output would then be found at compile time rather than run
time (assuming -many is removed from powerpc gcc, another little
project of mine).

-- 
Alan Modra
Australia Development Lab, IBM

  reply	other threads:[~2017-04-08  1:08 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-07  9:53 Alan Modra
2017-04-07 12:59 ` Peter Bergner
2017-04-08  1:08   ` Alan Modra [this message]
2017-04-10 16:40     ` Peter Bergner
2017-04-10 22:22       ` Alan Modra

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=20170408010756.GY16711@bubble.grove.modra.org \
    --to=amodra@gmail.com \
    --cc=bergner@vnet.ibm.com \
    --cc=binutils@sourceware.org \
    /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).