aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/arm/attr-neon-builtin-fail2.c
blob: ed0c4634b7727562cc407f08108bc2189e4a8f69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
/* Check that calling a neon builtin from a function compiled with vfp fails.  */
/* { dg-do compile } */
/* { dg-require-effective-target arm_neon_h_ok } */
/* { dg-options "-O2" } */
/* { dg-add-options arm_neon_h } */

extern __simd64_int8_t a, b;

__attribute__ ((target ("fpu=vfp")))
void
foo (__simd128_int16_t *p)
{
  *p = (__simd128_int16_t)__builtin_neon_vaddlsv8qi (a, b); /* { dg-error "You must enable NEON instructions .*" } */

}