public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH, rs6000] fold-vec-logical-ors-longlong test update
@ 2017-05-26 17:20 Will Schmidt
  2017-05-31 18:27 ` Segher Boessenkool
  0 siblings, 1 reply; 2+ messages in thread
From: Will Schmidt @ 2017-05-26 17:20 UTC (permalink / raw)
  To: GCC Patches, Segher Boessenkool, David Edelsohn; +Cc: Bill Schmidt

Hi, 

This test has been flaky on both AIX and in older linux based
environments. Notably, the number of xxlor instructions
generated varies depending on the platform and the specified
bit-size (32/64), with older environments generating either 6 or 24
xxlor instructions.  The behavior appears to level out on power8 targets,
so update this test to target power8-vector and specify the
-mpower8-vector option.

[gcc/testsuite]

2017-05-26  Will Schmidt  <will_schmidt@vnet.ibm.com>

	* gcc.target/powerpc/fold-vec-logical-ors-longlong.c:
	Update the target to powerpc_p8vector_ok. Update dg-options
	value to -mpower8-vector.


diff --git a/gcc/testsuite/gcc.target/powerpc/fold-vec-logical-ors-longlong.c b/gcc/testsuite/gcc.target/powerpc/fold-vec-logical-ors-longlong.c
index 7ca23fb..10c69d3 100644
--- a/gcc/testsuite/gcc.target/powerpc/fold-vec-logical-ors-longlong.c
+++ b/gcc/testsuite/gcc.target/powerpc/fold-vec-logical-ors-longlong.c
@@ -2,8 +2,8 @@
  * long long inputs produce the right results.  */
 
 /* { dg-do compile } */
-/* { dg-require-effective-target powerpc_vsx_ok } */
-/* { dg-options "-mvsx -O2" } */
+/* { dg-require-effective-target powerpc_p8vector_ok } */
+/* { dg-options "-mpower8-vector -O2" } */
 
 #include <altivec.h>
 
@@ -151,11 +151,11 @@ test6_nor (vector unsigned long long x, vector unsigned long long y)
   return *foo;
 }
 
-// Codegen on power7 is such that the vec_or() tests generate more xxlor
-// instructions than what is seen on power8 or newer.
-// Thus, an additional target clause for the xxlor instruction check.
-/* { dg-final { scan-assembler-times {\mxxlor\M} 6 { target p8vector_hw }  } } */
-/* { dg-final { scan-assembler-times {\mxxlor\M} 24 { target { ! p8vector_hw }  }  } } */
+// The number of xxlor instructions generated varies between 6 and 24 for
+// older systems (power6,power7), as well as for 32-bit versus 64-bit targets.
+// For simplicity, this test now only targets "powerpc_p8vector_ok" environments
+// where the answer is expected to be 6.
 
+/* { dg-final { scan-assembler-times {\mxxlor\M} 6 } } */
 /* { dg-final { scan-assembler-times {\mxxlxor\M} 6 } } */
 /* { dg-final { scan-assembler-times {\mxxlnor\M} 6 } } */


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

* Re: [PATCH, rs6000] fold-vec-logical-ors-longlong test update
  2017-05-26 17:20 [PATCH, rs6000] fold-vec-logical-ors-longlong test update Will Schmidt
@ 2017-05-31 18:27 ` Segher Boessenkool
  0 siblings, 0 replies; 2+ messages in thread
From: Segher Boessenkool @ 2017-05-31 18:27 UTC (permalink / raw)
  To: Will Schmidt; +Cc: GCC Patches, David Edelsohn, Bill Schmidt

On Fri, May 26, 2017 at 12:20:05PM -0500, Will Schmidt wrote:
> This test has been flaky on both AIX and in older linux based
> environments. Notably, the number of xxlor instructions
> generated varies depending on the platform and the specified
> bit-size (32/64), with older environments generating either 6 or 24
> xxlor instructions.  The behavior appears to level out on power8 targets,
> so update this test to target power8-vector and specify the
> -mpower8-vector option.

Okay for trunk.  Thanks!


Segher


> 2017-05-26  Will Schmidt  <will_schmidt@vnet.ibm.com>
> 
> 	* gcc.target/powerpc/fold-vec-logical-ors-longlong.c:
> 	Update the target to powerpc_p8vector_ok. Update dg-options
> 	value to -mpower8-vector.

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

end of thread, other threads:[~2017-05-31 18:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-26 17:20 [PATCH, rs6000] fold-vec-logical-ors-longlong test update Will Schmidt
2017-05-31 18:27 ` 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).