https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70830
Bug ID: 70830 Summary: ARM interrupt attribute: push/pop do not support {reglist}^ Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: fab...@ritter-vogt.de Target Milestone: --- Using attribute((interrupt)) on a function that accesses a local and a global variable causes gcc to emit broken assembly. It needs to be "ldm" instead of pop. Code: long *a; __attribute__((interrupt)) void fn1() { for (int x; x;) *(long *)8096384 = a[20 / x]; } Output: > >arm-none-eabi-gcc -c -Os test.c > test.s: Assembler messages: > test.s:47: Error: push/pop do not support {reglist}^ -- `pop > {r0,r1,r2,r3,pc}^'