Not 100% sure whether this is the preferred fix, but gcc.dg/vect/pr56787.c
has lots of float * parameters that point who-knows-where and so is only
vectorised if the target supports misaligned vector accesses:

void
foo (unsigned long n, const float *__restrict u0,
     const float *__restrict u1, const float *__restrict u2,
     const float *__restrict u3, const float *__restrict u4,
     const float *__restrict s0, const float *__restrict s1,
     const float *__restrict s2, float *__restrict t3,
     float *__restrict t4)
{
  unsigned long i;
  for (i = 0; i < n; i++)
    {
      float u[5], f[3][5];
      u[0] = u0[i]; u[1] = u1[i]; u[2] = u2[i]; u[3] = u3[i]; u[4] = u4[i];
      bar (u, f);
      t3[i] = s0[i] * f[0][3] + s1[i] * f[1][3] + s2[i] * f[2][3];
    }
}

MIPS paired-single doesn't have any form of vector misalignment.
I suppose it would be technically possible to use misaligned
integer accesses and an FPR<->GPR move, but that can be expensive.
I also don't have any hardware to benchmark it on.

So this patch adds an xfail for vect_no_align.  Tested on mipsisa64-sde-elf.
OK to install?

Thanks,
Richard


gcc/testsuite/
        * gcc.dg/vect/pr56787.c: Mark as xfail for vect_no_align.

Index: gcc/testsuite/gcc.dg/vect/pr56787.c
===================================================================
--- gcc/testsuite/gcc.dg/vect/pr56787.c 2014-02-10 20:26:03.870867802 +0000
+++ gcc/testsuite/gcc.dg/vect/pr56787.c 2014-02-10 20:36:42.072279177 +0000
@@ -31,5 +31,5 @@ foo (unsigned long n, const float *__res
     }
 }
 
-/* { dg-final { scan-tree-dump "vectorized 1 loops" "vect" } } */
+/* { dg-final { scan-tree-dump "vectorized 1 loops" "vect" { xfail 
vect_no_align } } } */
 /* { dg-final { cleanup-tree-dump "vect" } } */

Reply via email to