PR tree-optimization/83369 - Missing diagnostics during inlining
[official-gcc.git] / gcc / testsuite / gcc.dg / pr59523.c
bloba6c3302a6831d8ee840da4b39982e9b3ddb1a89f
1 /* PR tree-optimization/59523 */
2 /* { dg-do compile } */
3 /* { dg-options "-O3" } */
4 /* { dg-additional-options "-mavx2" { target { i?86-*-* x86_64-*-* } } } */
5 /* { dg-require-effective-target alloca } */
7 int *
8 foo (int a, int *b, int *c, int *d)
10 int i, *r = __builtin_alloca (a * sizeof (int));
11 __builtin_memcpy (r, d, a * sizeof (int));
12 for (i = 0; i < 64; i++)
13 c[i] += b[i];
14 for (i = 0; i < a; i++)
15 if (r[i] == 0)
16 r[i] = 1;
17 return r;