Patchwork Fix gcc.dg/vect/no-section-anchors-vect-64.c (PR testsuite/45429)

login
register
mail settings
Submitter Jakub Jelinek
Date Nov. 17, 2010, 11:03 a.m.
Message ID <20101117110320.GQ29412@tyan-ft48-01.lab.bos.redhat.com>
Download mbox | patch
Permalink /patch/71544/
State New
Headers show

Comments

Jakub Jelinek - Nov. 17, 2010, 11:03 a.m.
Hi!

This testcase expects peeling to be done in 2 loops to ensure proper
alignment.  As ia64 uses vectorization factor 2, the earlier change
from
int id[N][N][N];
to
int id[N][N][N+1];
made the 3rd loop:
  /* Multidimensional array. Not aligned: vectorizable. */
  for (i = 0; i < N; i++)
    {
      for (j = 0; j < N; j++)
        {
           id[i][1][j+1] = ib[i];
        }
    }
actually sufficiently aligned on ia64.
This patch changes it so that it is not aligned anywhere.

Ok for trunk?

2010-11-17  Jakub Jelinek  <jakub@redhat.com>

	PR testsuite/45429
	* gcc.dg/vect/no-section-anchors-vect-64.c: New test.


	Jakub
Richard Guenther - Nov. 17, 2010, 11:20 a.m.
On Wed, Nov 17, 2010 at 12:03 PM, Jakub Jelinek <jakub@redhat.com> wrote:
> Hi!
>
> This testcase expects peeling to be done in 2 loops to ensure proper
> alignment.  As ia64 uses vectorization factor 2, the earlier change
> from
> int id[N][N][N];
> to
> int id[N][N][N+1];
> made the 3rd loop:
>  /* Multidimensional array. Not aligned: vectorizable. */
>  for (i = 0; i < N; i++)
>    {
>      for (j = 0; j < N; j++)
>        {
>           id[i][1][j+1] = ib[i];
>        }
>    }
> actually sufficiently aligned on ia64.
> This patch changes it so that it is not aligned anywhere.
>
> Ok for trunk?

Ok.

Thanks,
Richard.

> 2010-11-17  Jakub Jelinek  <jakub@redhat.com>
>
>        PR testsuite/45429
>        * gcc.dg/vect/no-section-anchors-vect-64.c: New test.
>
> --- gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-64.c.jj   2010-11-17 11:18:22.000000000 +0100
> +++ gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-64.c      2010-11-17 11:17:39.000000000 +0100
> @@ -8,7 +8,7 @@
>  int ib[N] = {0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45};
>  int ia[N][4][N+1];
>  int ic[N][N][3][N+1];
> -int id[N][N][N+1];
> +int id[N][N][N+4];
>
>  __attribute__ ((noinline))
>  int main1 ()
>
>        Jakub
>

Patch

--- gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-64.c.jj	2010-11-17 11:18:22.000000000 +0100
+++ gcc/testsuite/gcc.dg/vect/no-section-anchors-vect-64.c	2010-11-17 11:17:39.000000000 +0100
@@ -8,7 +8,7 @@ 
 int ib[N] = {0,3,6,9,12,15,18,21,24,27,30,33,36,39,42,45};
 int ia[N][4][N+1];
 int ic[N][N][3][N+1];
-int id[N][N][N+1];
+int id[N][N][N+4];
 
 __attribute__ ((noinline))
 int main1 ()