gcc/testsuite/gcc.target/aarch64/target_attr_10.c
raw| 1 | /* { dg-do compile } */ |
| 2 | /* { dg-options "-O2 -march=armv8-a+simd -mcpu=generic" } */ |
| 3 | |
| 4 | /* Using a SIMD intrinsic from a function tagged with nosimd should fail |
| 5 | due to inlining rules. */ |
| 6 | |
| 7 | #include "arm_neon.h" |
| 8 | |
| 9 | __attribute__ ((target ("+nosimd"))) |
| 10 | uint8x16_t |
| 11 | foo (uint8x16_t a, uint8x16_t b, uint8x16_t c) |
| 12 | { |
| 13 | return vbslq_u8 (a, b, c); /* { dg-message "called from here" } */ |
| 14 | } |
| 15 | |
| 16 | /* { dg-error "inlining failed in call to 'always_inline'" "" { target *-*-* } 0 } */ |