2018-03-15 Steven G. Kargl <kargl@gcc.gnu.org>
[official-gcc.git] / gcc / testsuite / gcc.target / arc / firq-4.c
blob03d3746a500dda9f9e82fe6728d995b6aea6e6cd
1 /* { dg-do compile } */
2 /* { dg-require-effective-target archs }*/
3 /* { dg-options "-O2 -mll64 -mrgf-banked-regs=16" } */
5 /* Check if R4-R9 and R16-R25 are correctly saved on stack. */
7 void __attribute__ ((interrupt("firq")))
8 handler1 (void)
10 asm volatile (""
13 : "r0", "r1", "r2", "r3", "r4",
14 "r5", "r6", "r7", "r8", "r9",
15 "r10", "r11", "r12", "r13", "r14",
16 "r15", "r16", "r17", "r18", "r19",
17 "r20", "r21", "r22", "r23", "r24",
18 "r25", "fp");
20 /* { dg-final { scan-assembler-times "r4,\\\[sp" 2 } } */
21 /* { dg-final { scan-assembler-times "r6,\\\[sp,\[0-9\]+\\\]" 2 } } */
22 /* { dg-final { scan-assembler-times "r8,\\\[sp,\[0-9\]+\\\]" 2 } } */
24 /* { dg-final { scan-assembler-times "r16,\\\[sp,\[0-9\]+\\\]" 2 } } */
25 /* { dg-final { scan-assembler-times "r18,\\\[sp,\[0-9\]+\\\]" 2 } } */
26 /* { dg-final { scan-assembler-times "r20,\\\[sp,\[0-9\]+\\\]" 2 } } */
27 /* { dg-final { scan-assembler-times "r24,\\\[sp,\[0-9\]+\\\]" 2 } } */
29 /* { dg-final { scan-assembler-not "fp,\\\[sp" } } */
30 /* { dg-final { scan-assembler-not "push.*fp" } } */
31 /* { dg-final { scan-assembler "mov_s.*fp,sp" } } */