Update concepts branch to revision 131834
[official-gcc.git] / gcc / testsuite / gcc.target / mips / save-restore-4.c
blob13f1f0454ee74c94b6ee35d3f1c593be2f4264a5
1 /* Check that we can use the save instruction to save $16, $17 and $31. */
2 /* { dg-do compile { target mips16_attribute } } */
3 /* { dg-mips-options "-mips32r2 -mabi=32 -O2" } */
4 /* { dg-add-options mips16_attribute } */
6 void bar (void);
8 MIPS16 void
9 foo (void)
11 bar ();
12 asm volatile ("" ::: "$16", "$17");
14 /* { dg-final { scan-assembler "\tsave\t\[0-9\]*,\\\$16,\\\$17,\\\$31" } } */
15 /* { dg-final { scan-assembler "\trestore\t\[0-9\]*,\\\$16,\\\$17,\\\$31" } } */