| 1 |
/* { dg-do link } */ |
| 2 |
/* { dg-require-effective-target arm_arch_v8_1m_main_link } */ /* Make sure we have suitable multilibs to link successfully. */ |
| 3 |
/* { dg-require-effective-target arm_v8_1m_mve_ok } */ |
| 4 |
/* { dg-add-options arm_v8_1m_mve } */ |
| 5 |
/* { dg-additional-options "-O2 -flto" } */ |
| 6 |
|
| 7 |
/* Check MVE intrinsics with LTO with __ARM_MVE_PRESERVE_USER_NAMESPACE and a |
| 8 |
user-overridden intrinsic. */ |
| 9 |
|
| 10 |
#define __ARM_MVE_PRESERVE_USER_NAMESPACE |
| 11 |
#include <arm_mve.h> |
| 12 |
|
| 13 |
int global_int; |
| 14 |
int32_t vaddvq(int8x16_t x) |
| 15 |
{ |
| 16 |
return global_int + __arm_vgetq_lane_s8 (x, 0); |
| 17 |
} |
| 18 |
|
| 19 |
int main(int argc, char* argv[]) |
| 20 |
{ |
| 21 |
global_int = argc; |
| 22 |
return vaddvq(__arm_vdupq_n_s8 (argc)); |
| 23 |
} |