Commit 5bb12090 by Ira Rosen Committed by Ira Rosen

costmodel-vect-31d.c: Remove.


	* gcc.dg/vect/costmodel/ppc/costmodel-vect-31d.c: Remove.
	* gcc.dg/vect/costmodel/ppc/costmodel-vect-76a.c: Increase loop bound.
	* gcc.dg/vect/costmodel/ppc/costmodel-vect-76b.c: Likewise.
	* gcc.dg/vect/costmodel/ppc/costmodel-vect-68d.c: Remove.
	* gcc.dg/vect/pr35821-altivec.c, gcc.dg/vect/pr35821-spu.c: Likewise.

From-SVN: r161819
parent 6698dd72
2010-07-05 Ira Rosen <irar@il.ibm.com>
* gcc.dg/vect/costmodel/ppc/costmodel-vect-31d.c: Remove.
* gcc.dg/vect/costmodel/ppc/costmodel-vect-76a.c: Increase loop bound.
* gcc.dg/vect/costmodel/ppc/costmodel-vect-76b.c: Likewise.
* gcc.dg/vect/costmodel/ppc/costmodel-vect-68d.c: Remove.
* gcc.dg/vect/pr35821-altivec.c, gcc.dg/vect/pr35821-spu.c: Likewise.
2010-07-05 Shujing Zhao <pearly.zhao@oracle.com>
PR c++/22138
......
/* { dg-require-effective-target vect_int } */
#include <stdarg.h>
#include "../../tree-vect.h"
#define N 5
struct t{
int k[N];
int l;
};
struct s{
char a; /* aligned */
char b[N-1]; /* unaligned (offset 1B) */
char c[N]; /* aligned (offset NB) */
struct t d; /* aligned (offset 2NB) */
struct t e; /* unaligned (offset 2N+4N+4 B) */
};
int main1 ()
{
int i;
struct s tmp;
/* unaligned */
for (i = 0; i < N; i++)
{
tmp.e.k[i] = 8;
}
/* check results: */
for (i = 0; i < N; i++)
{
if (tmp.e.k[i] != 8)
abort ();
}
return 0;
}
int main (void)
{
check_vect ();
return main1 ();
}
/* { dg-final { scan-tree-dump-times "vectorization not profitable" 1 "vect" } } */
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 0 "vect" } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
/* { dg-require-effective-target vect_int } */
#include <stdarg.h>
#include "../../tree-vect.h"
#define N 11
struct s{
int m;
int n[N][N][N];
};
struct test1{
struct s a; /* array a.n is unaligned */
int b;
int c;
struct s e; /* array e.n is aligned */
};
int main1 ()
{
int i,j;
struct test1 tmp1;
/* 4. unaligned */
for (i = 3; i < N-3; i++)
{
tmp1.e.n[1][2][i] = 8;
}
/* check results: */
for (i = 3; i <N-3; i++)
{
if (tmp1.e.n[1][2][i] != 8)
abort ();
}
return 0;
}
int main (void)
{
check_vect ();
return main1 ();
}
/* { dg-final { scan-tree-dump-times "vectorization not profitable" 1 "vect" } } */
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 0 "vect" } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
......@@ -3,7 +3,7 @@
#include <stdarg.h>
#include "../../tree-vect.h"
#define N 8
#define N 16
#define OFF 4
/* Check handling of accesses for which the "initial condition" -
......
......@@ -3,7 +3,7 @@
#include <stdarg.h>
#include "../../tree-vect.h"
#define N 8
#define N 16
#define OFF 4
/* Check handling of accesses for which the "initial condition" -
......
/* { dg-do compile { target { powerpc_altivec_ok } } } */
#include "altivec.h"
void
foo (float f_gain1, int n_tail, float * __restrict__ f_in_hptr,
float * __restrict__ f_out_hptr)
{
int i;
vector float *v_f_in_hptr, *v_f_out_hptr;
f_in_hptr = ( float* )v_f_in_hptr;
f_out_hptr = ( float* )v_f_out_hptr;
for( i = 0 ; i < n_tail ; i++ ) {
f_out_hptr[0] = f_in_hptr[0] * f_gain1;
f_in_hptr++;
f_out_hptr++;
}
}
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
/* { dg-do compile { target { spu-*-* } } } */
void
foo (float f_gain1, int n_tail, float * __restrict__ f_in_hptr,
float * __restrict__ f_out_hptr)
{
int i;
__attribute__((__spu_vector__)) float *v_f_in_hptr, *v_f_out_hptr;
f_in_hptr = ( float* )v_f_in_hptr;
f_out_hptr = ( float* )v_f_out_hptr;
for( i = 0 ; i < n_tail ; i++ ) {
f_out_hptr[0] = f_in_hptr[0] * f_gain1;
f_in_hptr++;
f_out_hptr++;
}
}
/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
/* { dg-final { cleanup-tree-dump "vect" } } */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment