This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH] Add initial POWER8 and HTM support
- From: Alan Modra <amodra at gmail dot com>
- To: Peter Bergner <bergner at vnet dot ibm dot com>
- Cc: "binutils at sourceware dot org" <binutils at sourceware dot org>
- Date: Fri, 11 Jan 2013 10:24:44 +1030
- Subject: Re: [PATCH] Add initial POWER8 and HTM support
- References: <1357857961.29491.3274.camel@otta>
On Thu, Jan 10, 2013 at 04:46:01PM -0600, Peter Bergner wrote:
> include/opcode/
> * ppc.h (PPC_OPCODE_POWER8): New define.
> (PPC_OPCODE_HTM): Likewise.
>
> opcodes/
> * ppc-dis.c (ppc_opts): Add "power8", "pwr8" and "htm" entries.
> * ppc-opc.c (HTM_R, HTM_SI, XRTRB_MASK, XRTRARB_MASK, XRTLRARB_MASK,
> XRTARARB_MASK, XRTBFRARB_MASK, XRCL, POWER8, PPCHTM): New defines.
> (SH6): Update.
> <"tabort.", "tabortdc.", "tabortdci.", "tabortwc.",
> "tabortwci.", "tbegin.", "tcheck", "tend.", "trechkpt.",
> "treclaim.", "tsr.">: Add POWER8 HTM opcodes.
> <"tendall.", "tresume.", "tsuspend.">: Add POWER8 HTM extended opcodes.
>
> gas/
> * doc/as.texinfo (Target PowerPC): Document -mpower8 and -mhtm.
> * doc/c-ppc.texi (PowerPC-Opts): Likewise.
> * config/tc-ppc.c (md_show_usage): Likewise.
> (ppc_handle_align): Handle power8's group ending nop.
>
> gas/testsuite/
> * gas/ppc/htm.d: New test.
> * gas/ppc/htm.s: Likewise.
> * gas/ppc/power8.d: Likewise.
> * gas/ppc/power8.s: Likewise.
> * gas/ppc/ppc.exp: Run them.
OK, but..
> Index: opcodes/ppc-dis.c
> ===================================================================
> RCS file: /cvs/src/src/opcodes/ppc-dis.c,v
> retrieving revision 1.61
> diff -u -p -r1.61 ppc-dis.c
> --- opcodes/ppc-dis.c 23 Nov 2012 03:28:11 -0000 1.61
> +++ opcodes/ppc-dis.c 10 Jan 2013 20:01:26 -0000
> @@ -147,6 +147,11 @@ struct ppc_mopt ppc_opts[] = {
> | PPC_OPCODE_POWER4 | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6
> | PPC_OPCODE_POWER7 | PPC_OPCODE_ALTIVEC | PPC_OPCODE_VSX),
> 0 },
> + { "power8", (PPC_OPCODE_PPC | PPC_OPCODE_ISEL | PPC_OPCODE_64
> + | PPC_OPCODE_POWER4 | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6
> + | PPC_OPCODE_POWER7 | PPC_OPCODE_POWER8 | PPC_OPCODE_HTM
> + | PPC_OPCODE_ALTIVEC | PPC_OPCODE_ALTIVEC2 | PPC_OPCODE_VSX),
> + 0 },
> { "ppc", (PPC_OPCODE_PPC),
> 0 },
> { "ppc32", (PPC_OPCODE_PPC),
> @@ -176,6 +181,11 @@ struct ppc_mopt ppc_opts[] = {
> | PPC_OPCODE_POWER4 | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6
> | PPC_OPCODE_POWER7 | PPC_OPCODE_ALTIVEC | PPC_OPCODE_VSX),
> 0 },
> + { "pwr8", (PPC_OPCODE_PPC | PPC_OPCODE_ISEL | PPC_OPCODE_64
> + | PPC_OPCODE_POWER4 | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6
> + | PPC_OPCODE_POWER7 | PPC_OPCODE_POWER8
> + | PPC_OPCODE_ALTIVEC | PPC_OPCODE_ALTIVEC2 | PPC_OPCODE_VSX),
> + 0 },
please make the power8 and pwr8 entries identical. You're missing
PPC_OPCODE_HTM from pwr8.
--
Alan Modra
Australia Development Lab, IBM