Fix vext[us]64_1.c test on ARM by unsharing test body.
[official-gcc.git] / gcc / testsuite / gcc.target / aarch64 / simd / ext_u64_1.c
blob644b73202567fdb5fdc779f48bf398c9e5268c00
1 /* Test the `vextu64' AArch64 SIMD intrinsic. */
3 /* { dg-do run } */
4 /* { dg-options "-save-temps -O3 -fno-inline" } */
6 #include "arm_neon.h"
8 extern void abort (void);
10 int
11 main (int argc, char **argv)
13 uint64_t arr1[] = {0};
14 uint64x1_t in1 = vld1_u64 (arr1);
15 uint64_t arr2[] = {1};
16 uint64x1_t in2 = vld1_u64 (arr2);
17 uint64x1_t actual = vext_u64 (in1, in2, 0);
18 if (actual[0] != in1[0])
19 abort ();
21 return 0;
24 /* Do not scan-assembler. An EXT instruction could be emitted, but would merely
25 return its first argument, so it is legitimate to optimize it out. */
26 /* { dg-final { cleanup-saved-temps } } */