public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH, rs6000] Add testcase coverage for vec_sums built-in
@ 2017-08-17 14:36 Will Schmidt
  2017-08-18 21:49 ` Segher Boessenkool
  0 siblings, 1 reply; 2+ messages in thread
From: Will Schmidt @ 2017-08-17 14:36 UTC (permalink / raw)
  To: GCC Patches
  Cc: Segher Boessenkool, Carl E. Love, Bill Schmidt, David Edelsohn

Hi, 

[Patch, rs6000] Add testcase coverage for vec_sums built-in

Add some testcase coverage for the vec_sums() built-in.

Tested across power platforms (p6 and newer). OK for trunk?

Thanks,
-Will

[gcc/testsuite]

2017-08-17  Will Schmidt  <will_schmidt@vnet.ibm.com>

	* gcc.target/powerpc/fold-vec-sums-int.c: New.

diff --git a/gcc/testsuite/gcc.target/powerpc/fold-vec-sums-int.c b/gcc/testsuite/gcc.target/powerpc/fold-vec-sums-int.c
new file mode 100644
index 0000000..6ef5f3b
--- /dev/null
+++ b/gcc/testsuite/gcc.target/powerpc/fold-vec-sums-int.c
@@ -0,0 +1,16 @@
+/* Verify that overloaded built-ins for vec_sums with int
+   inputs produce the right results.  */
+
+/* { dg-do compile } */
+/* { dg-require-effective-target powerpc_altivec_ok } */
+/* { dg-options "-maltivec -O2" } */
+
+#include <altivec.h>
+
+vector signed int
+test_vec_sums (vector signed int vsi2, vector signed int vsi3)
+{
+  return vec_sums (vsi2, vsi3);
+}
+
+/* { dg-final { scan-assembler-times "vsumsws" 1 } } */


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

* Re: [PATCH, rs6000] Add testcase coverage for vec_sums built-in
  2017-08-17 14:36 [PATCH, rs6000] Add testcase coverage for vec_sums built-in Will Schmidt
@ 2017-08-18 21:49 ` Segher Boessenkool
  0 siblings, 0 replies; 2+ messages in thread
From: Segher Boessenkool @ 2017-08-18 21:49 UTC (permalink / raw)
  To: Will Schmidt; +Cc: GCC Patches, Carl E. Love, Bill Schmidt, David Edelsohn

On Thu, Aug 17, 2017 at 09:18:54AM -0500, Will Schmidt wrote:
> Add some testcase coverage for the vec_sums() built-in.
> 
> Tested across power platforms (p6 and newer). OK for trunk?

Okay, thanks!


Segher


> 	* gcc.target/powerpc/fold-vec-sums-int.c: New.

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

end of thread, other threads:[~2017-08-18 21:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-17 14:36 [PATCH, rs6000] Add testcase coverage for vec_sums built-in Will Schmidt
2017-08-18 21:49 ` 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).