mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-03 09:48:29 +00:00
Make more code aarch64 friendly
This commit is contained in:
parent
ca2860947f
commit
2b73e72d59
568 changed files with 2197 additions and 1061 deletions
|
@ -26,6 +26,7 @@
|
|||
// @return 0 on success, or -1 w/ errno
|
||||
// @norestart
|
||||
sched_yield:
|
||||
#ifdef __x86_64__
|
||||
push %rbp
|
||||
mov %rsp,%rbp
|
||||
xor %eax,%eax
|
||||
|
@ -86,5 +87,15 @@ sched_yield:
|
|||
|
||||
9: leave
|
||||
ret
|
||||
|
||||
#elif defined(__aarch64__)
|
||||
mov x8,#0x7c
|
||||
svc 0
|
||||
mov w0,#0
|
||||
ret
|
||||
|
||||
#else
|
||||
#error "arch unsupported"
|
||||
#endif
|
||||
.endfn sched_yield,globl
|
||||
.previous
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue