| 1 |
extern void abort (void); |
| 2 |
|
| 3 |
int16x4x2_t |
| 4 |
test_vzips16 (int16x4_t _a, int16x4_t _b) |
| 5 |
{ |
| 6 |
return vzip_s16 (_a, _b); |
| 7 |
} |
| 8 |
|
| 9 |
int |
| 10 |
main (int argc, char **argv) |
| 11 |
{ |
| 12 |
int i; |
| 13 |
int16_t first[] = {1, 2, 3, 4}; |
| 14 |
int16_t second[] = {5, 6, 7, 8}; |
| 15 |
int16x4x2_t result = test_vzips16 (vld1_s16 (first), vld1_s16 (second)); |
| 16 |
int16x4_t res1 = result.val[0], res2 = result.val[1]; |
| 17 |
int16_t exp1[] = {1, 5, 2, 6}; |
| 18 |
int16_t exp2[] = {3, 7, 4, 8}; |
| 19 |
int16x4_t expected1 = vld1_s16 (exp1); |
| 20 |
int16x4_t expected2 = vld1_s16 (exp2); |
| 21 |
|
| 22 |
for (i = 0; i < 4; i++) |
| 23 |
if ((res1[i] != expected1[i]) || (res2[i] != expected2[i])) |
| 24 |
abort (); |
| 25 |
|
| 26 |
return 0; |
| 27 |
} |