view gcc/testsuite/gcc.dg/graphite/isl-ast-gen-blocks-4.c @ 145:1830386684a0

gcc-9.2.0
author anatofuz
date Thu, 13 Feb 2020 11:34:05 +0900
parents 04ced10e8804
children
line wrap: on
line source

static int __attribute__((noinline))
foo (int k, int n1, int n2, int n3)
{
  int j, res = 0;
  for (j = 0; j < k; j++)
    {
      int i;
      for (i = 0; i < n1; i++)
        res += i;
      for (i = 0; i < n2; i++)
        res += i;
      for (i = 0; i < n3; i++)
        res += i;
    }

  return res;
}

extern void abort ();

int
main (void)
{ 
  int res = foo (4, 50, 50, 50);
  if (res != 14700)
    abort ();

  return 0;
}