public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH, rs6000] PR 80982 gcc.target/powerpc/builtins-3-runnable.c fails starting with its introduction in r248846
@ 2017-06-07 19:16 Carl E. Love
  2017-06-07 21:23 ` Segher Boessenkool
  0 siblings, 1 reply; 2+ messages in thread
From: Carl E. Love @ 2017-06-07 19:16 UTC (permalink / raw)
  To: gcc-patches, David Edelsohn, Segher Boessenkool; +Cc: Bill Schmidt, cel

GCC Maintainers:

The support for vec_doublel () builtin didn't get re-tested on BE before
submission.  The following buzilla was filed against the builtin
support.


Bug 80982 - gcc.target/powerpc/builtins-3-runnable.c fails starting with
its introduction in r248846. 

The failure was due to GEN_INT (8) being out of bounds.  Once that was
fixed, the order of the arguments also needed fixing to get the correct
result.  These changes only apply to the BE code.

The following patch has been tested on powerpc64le-unknown-linux-gnu
(Power 8 LE) and on powerpc64-unknown-linux-gnu (Power 8 BE) with no
regressions.

Is the patch OK for gcc mainline?

                  Carl Love

-----------------------------------------------------
PR 80982 gcc.target/powerpc/builtins-3-runnable.c fails
 starting 	with its introduction in r248846.

gcc/ChangeLog:

2017-06-07  Carl Love  <cel@us.ibm.com>

	PR target/80982
	* config/rs6000/altivec.md: Fix the implementation of
	(define_expand "doublel<mode>2" for BE.
---
 gcc/config/rs6000/altivec.md | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/gcc/config/rs6000/altivec.md b/gcc/config/rs6000/altivec.md
index 9e592bc..487b9a4 100644
--- a/gcc/config/rs6000/altivec.md
+++ b/gcc/config/rs6000/altivec.md
@@ -3002,9 +3002,9 @@
       emit_insn (gen_vsx_xxsldwi_<mode> (rtx_tmp, operands[1],
 					 operands[1], rtx_val));
 
-      rtx_val = GEN_INT (8);
-      emit_insn (gen_vsx_xxsldwi_<mode> (rtx_tmp, rtx_tmp,
-					 operands[1],rtx_val));
+      rtx_val = GEN_INT (2);
+      emit_insn (gen_vsx_xxsldwi_<mode> (rtx_tmp, operands[1],
+					 rtx_tmp, rtx_val));
       emit_insn (gen_vsx_xvcv<VS_sxwsp>dp (operands[0], rtx_tmp));
     }
   else
-- 
1.9.1



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH, rs6000] PR 80982 gcc.target/powerpc/builtins-3-runnable.c fails starting with its introduction in r248846
  2017-06-07 19:16 [PATCH, rs6000] PR 80982 gcc.target/powerpc/builtins-3-runnable.c fails starting with its introduction in r248846 Carl E. Love
@ 2017-06-07 21:23 ` Segher Boessenkool
  0 siblings, 0 replies; 2+ messages in thread
From: Segher Boessenkool @ 2017-06-07 21:23 UTC (permalink / raw)
  To: Carl E. Love; +Cc: gcc-patches, David Edelsohn, Bill Schmidt

On Wed, Jun 07, 2017 at 12:16:09PM -0700, Carl E. Love wrote:
> Bug 80982 - gcc.target/powerpc/builtins-3-runnable.c fails starting with
> its introduction in r248846. 
> 
> The failure was due to GEN_INT (8) being out of bounds.  Once that was
> fixed, the order of the arguments also needed fixing to get the correct
> result.  These changes only apply to the BE code.
> 
> The following patch has been tested on powerpc64le-unknown-linux-gnu
> (Power 8 LE) and on powerpc64-unknown-linux-gnu (Power 8 BE) with no
> regressions.
> 
> Is the patch OK for gcc mainline?

Yes please.  Modulo a changelog thing:

> 2017-06-07  Carl Love  <cel@us.ibm.com>
> 
> 	PR target/80982
> 	* config/rs6000/altivec.md: Fix the implementation of
> 	(define_expand "doublel<mode>2" for BE.

	* config/rs6000/altivec.md (double<mode>2): Fix the implementation
	for BE.

Thanks,


Segher

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-06-07 21:23 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-07 19:16 [PATCH, rs6000] PR 80982 gcc.target/powerpc/builtins-3-runnable.c fails starting with its introduction in r248846 Carl E. Love
2017-06-07 21:23 ` Segher Boessenkool

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).