diff mbox

[PR66702] Skip pr48052 on targets not support vect_int_mult

Message ID 000001d0b566$9f456040$ddd020c0$@arm.com
State New
Headers show

Commit Message

Bin Cheng July 3, 2015, 8:02 a.m. UTC
Hi,
The test failed on sparc because sparc doesn't support vect_int_mult.  This
patch adds the prerequisite condition thus skips test on such platforms.

An obvious change, will apply it in 24h.

Thanks,
bin

gcc/testsuite/ChangeLog
2015-07-02  Bin Cheng  <bin.cheng@arm.com>

	PR tree-optimization/66720
	* gcc.dg/vect/pr48052.c: Use dg-require-effective-target
	vect_int_mult.

Comments

Jeff Law July 6, 2015, 8:17 p.m. UTC | #1
On 07/03/2015 02:02 AM, Bin Cheng wrote:
> Hi,
> The test failed on sparc because sparc doesn't support vect_int_mult.  This
> patch adds the prerequisite condition thus skips test on such platforms.
>
> An obvious change, will apply it in 24h.
>
> Thanks,
> bin
>
> gcc/testsuite/ChangeLog
> 2015-07-02  Bin Cheng  <bin.cheng@arm.com>
>
> 	PR tree-optimization/66720
> 	* gcc.dg/vect/pr48052.c: Use dg-require-effective-target
> 	vect_int_mult.
OK.
jeff
>
diff mbox

Patch

Index: gcc/testsuite/gcc.dg/vect/pr48052.c
===================================================================
--- gcc/testsuite/gcc.dg/vect/pr48052.c	(revision 225094)
+++ gcc/testsuite/gcc.dg/vect/pr48052.c	(working copy)
@@ -1,9 +1,9 @@ 
 /* { dg-do compile } */
-/* { dg-additional-options "-O3" } */
+/* { dg-require-effective-target vect_int_mult } */
 
 int foo(int* A, int* B,  unsigned start, unsigned BS)
 {
-  int s;
+  int s = 0;
   for (unsigned k = start;  k < start + BS; k++)
     {
       s += A[k] * B[k];
@@ -14,7 +14,7 @@  int foo(int* A, int* B,  unsigned start, unsigned
 
 int bar(int* A, int* B, unsigned BS)
 {
-  int s;
+  int s = 0;
   for (unsigned k = 0;  k < BS; k++)
     {
       s += A[k] * B[k];