view gcc/testsuite/gcc.dg/tree-ssa/loop-interchange-11.c @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents
children 1830386684a0
line wrap: on
line source

/* { dg-do compile } */
/* { dg-options "-O2 -floop-interchange -fdump-tree-linterchange-details" } */
/* { dg-skip-if "too big data segment" { avr-*-* visium-*-* } } */

#define M 256
int a[M][M], b[M][M];

void
simple_reduc_1 (int n, int *p)
{
  for (int j = 0; j < n; j++)
    {
      int sum = p[j];
      for (int i = 0; i < n; i++)
	{
	  sum = sum + b[i][j];
	  b[i][j] += a[i][j];
	}

      p[j] = sum;
    }
}
/* { dg-final { scan-tree-dump-not "Loop_pair<outer:., inner:.> is interchanged" "linterchange" } } */