This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix powerpc movsi_from_sf define_insn_and_split constraints (PR target/79354)
- From: Segher Boessenkool <segher at kernel dot crashing dot org>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: David Edelsohn <dje dot gcc at gmail dot com>, Michael Meissner <meissner at linux dot vnet dot ibm dot com>, gcc-patches at gcc dot gnu dot org
- Date: Fri, 3 Feb 2017 09:59:45 -0600
- Subject: Re: [PATCH] Fix powerpc movsi_from_sf define_insn_and_split constraints (PR target/79354)
- Authentication-results: sourceware.org; auth=none
- References: <20170203091047.GC14051@tucnak>
Hi Jakub,
On Fri, Feb 03, 2017 at 10:10:47AM +0100, Jakub Jelinek wrote:
> As mentioned in the PR, for the following testcase we emit a power9
> instruction even with -mcpu=power8. Similar movsf_hardfloat instruction
> uses wb constraint for the stxssp insn source rather than wu, which it
> only uses for stxsspx (power7?).
>
> Bootstrapped/regtested on powerpc64{,le}-linux, ok for trunk?
Yes please. Thanks!
Some testcase stuff below...
> --- gcc/testsuite/gcc.target/powerpc/pr79354.c.jj 2017-02-03 02:37:44.147938375 +0100
> +++ gcc/testsuite/gcc.target/powerpc/pr79354.c 2017-02-03 02:38:34.838303987 +0100
> @@ -0,0 +1,23 @@
> +/* PR target/79354 */
> +/* { dg-do compile { target { powerpc64*-*-* && lp64 } } } */
powerpc*-*-* instead? And why is lp64 needed?
> +/* { dg-skip-if "do not override -mcpu" { powerpc*-*-* } { "-mcpu=*" } { "-mcpu=power8" } } */
> +/* { dg-require-effective-target powerpc_p8vector_ok } */
> +/* { dg-options "-mcpu=power8 -O2" } */
> +/* { dg-final { scan-assembler-not "stxssp\[^x]" } } */
\M is nicer and more future-proof, but this works.
Segher