aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.target/arm/pr45094.c
blob: f35e7bb2d7f1ed6ab41447a200811d062530f019 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
/* { dg-do run } */
/* { dg-skip-if "incompatible options" { arm*-*-* } { "-march=*" } { "-march=armv7-a" } } */
/* { dg-require-effective-target arm_neon_hw } */
/* { dg-options "-O2 -mcpu=cortex-a8" } */
/* { dg-add-options arm_neon } */

#include <stdlib.h>

long long buffer[32];

void __attribute__((noinline)) f(long long *p, int n)
{
  while (--n >= 0)
    {
      *p = 1;
      p += 32;
    }
}

int main(void)
{
  f(buffer, 1);
  
  if (!buffer[0])
    abort();

  return 0;
}