Skip to content

Commit 2f14768

Browse files
authored
Merge pull request #7368 from dhalbert/preserve-nlr_push-regs
Use returns_twice attribute to preserve regs in nlrthumb nlr_push()
2 parents 2a1bb72 + 8087887 commit 2f14768

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

py/nlrthumb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
// For reference, arm/thumb callee save regs are:
3737
// r4-r11, r13=sp
3838

39-
__attribute__((naked)) unsigned int nlr_push(nlr_buf_t *nlr) {
39+
__attribute__((naked, returns_twice)) unsigned int nlr_push(nlr_buf_t *nlr) {
4040

4141
__asm volatile (
4242
"str r4, [r0, #12] \n" // store r4 into nlr_buf

0 commit comments

Comments
 (0)