gcc/testsuite/gcc.target/aarch64/vec-init-15.c
raw| 1 | /* { dg-do compile } */ |
| 2 | /* { dg-options "-O" } */ |
| 3 | |
| 4 | #include <arm_neon.h> |
| 5 | |
| 6 | int32x2_t f1(int32_t *x, int c) { |
| 7 | return c ? (int32x2_t) { x[0], x[2] } : (int32x2_t) { 0, 0 }; |
| 8 | } |
| 9 | |
| 10 | int32x2_t f2(int32_t *x, int i0, int i1, int c) { |
| 11 | return c ? (int32x2_t) { x[i0], x[i1] } : (int32x2_t) { 0, 0 }; |
| 12 | } |
| 13 | |
| 14 | /* { dg-final { scan-assembler-times {\t(?:ldr\ts[0-9]+|ld1\t)} 4 } } */ |
| 15 | /* { dg-final { scan-assembler-not {\tldr\tw} } } */ |