mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-30 16:28:30 +00:00
Make progress towards aarch64 build
This commit is contained in:
parent
08ff26c817
commit
ca2860947f
15428 changed files with 25694 additions and 23138 deletions
|
@ -43,6 +43,7 @@ __msabi extern typeof(ExitThread) *const __imp_ExitThread;
|
|||
* @noreturn
|
||||
*/
|
||||
privileged wontreturn void _Exit1(int rc) {
|
||||
#ifdef __x86_64__
|
||||
char cf;
|
||||
int ax, dx, di, si;
|
||||
if (!IsWindows() && !IsMetal()) {
|
||||
|
@ -72,4 +73,13 @@ privileged wontreturn void _Exit1(int rc) {
|
|||
unreachable;
|
||||
}
|
||||
notpossible;
|
||||
#elif defined(__aarch64__)
|
||||
register long r0 asm("x0") = rc;
|
||||
asm volatile("mov\tx8,%1\n"
|
||||
"svc\t0"
|
||||
: /* no outputs */
|
||||
: "i"(93), "r"(r0)
|
||||
: "x8", "memory");
|
||||
notpossible;
|
||||
#endif
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue