1 /* { dg-do assemble { target aarch64_asm_sve_ok } } */
2 /* { dg-additional-options "-O0 -msve-vector-bits=256 -mbig-endian --save-temps" } */
3
4 typedef struct _b {
5 __attribute__((__vector_size__(32))) int a[2];
6 } b;
7
8 b *c;
9
10 void
foo(void)11 foo (void)
12 {
13 char *p = '\0';
14 b e = c[0];
15 }
16
17 /* { dg-final { scan-assembler {\tld1w\tz[0-9]+.s, p[0-9]+/z, \[x[0-9]+\]\n} } } */
18 /* { dg-final { scan-assembler {\tld1w\tz[0-9]+.s, p[0-9]+/z, \[x[0-9]+, #1, mul vl\]\n} } } */
19 /* { dg-final { scan-assembler {\tst1w\tz[0-9]+.s, p[0-9]+, \[(sp|x[0-9]+)\]\n} } } */
20 /* { dg-final { scan-assembler {\tst1w\tz[0-9]+.s, p[0-9]+, \[(sp|x[0-9]+), #1, mul vl\]\n} } } */
21
22