aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/vect/pr103494.c
blob: b544bf2379c551ff5114ae2d93794c535eeec713 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/* { dg-do compile } */
/* { dg-additional-options "-O3" } */

typedef int T1;
typedef signed char T2;

T1
f (T1 *d, T2 *x, int n)
{
  unsigned char res = 0;
  for (int i = 0; i < n; ++i)
    res += d[x[i]];
  return res;
}