2014-09-25 Sandra Loosemore <sandra@codesourcery.com>
[official-gcc.git] / gcc / testsuite / gcc.dg / vect / pr60196-2.c
blob62ef8b1c0083bdb30770de510a04be8cd180ac5c
1 /* PR tree-optimization/63189 */
3 #include "tree-vect.h"
5 static const short a[8] = {1, 1, 1, 1, 1, 1, 1, 1 };
6 static const unsigned char b[8] = {0, 0, 0, 0, 0, 0, 0, 0 };
8 __attribute__((noinline, noclone)) static int
9 bar (void)
11 int sum = 0, i;
12 for (i = 0; i < 8; ++i)
13 sum += a[i] * b[i];
14 return sum;
17 __attribute__((noinline, noclone)) void
18 foo (void)
20 if (bar () != 0)
21 abort ();
24 int
25 main ()
27 check_vect ();
28 foo ();
29 return 0;
32 /* { dg-final { cleanup-tree-dump "vect" } } */