rt: Use %ecx instead of %eax during the second half of __morestack
If Rust code made use of return values then using %eax here would clobber it
This commit is contained in:
parent
a195ab2dd9
commit
f332643e7f
1 changed files with 5 additions and 3 deletions
|
|
@ -122,11 +122,13 @@ MORESTACK:
|
|||
|
||||
subl $8, %esp // Alignment
|
||||
|
||||
// Now that we're on the return path we want to avoid
|
||||
// stomping on %eax
|
||||
#ifdef __APPLE__
|
||||
call 1f
|
||||
1: popl %eax
|
||||
movl L_upcall_del_stack$non_lazy_ptr-1b(%eax),%eax
|
||||
pushl %eax
|
||||
1: popl %ecx
|
||||
movl L_upcall_del_stack$non_lazy_ptr-1b(%ecx),%ecx
|
||||
pushl %ecx
|
||||
#else
|
||||
pushl $UPCALL_DEL_STACK
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue