Make minor improvements

- Work towards simplifying ape.S startup process
- Rewrote ar because it took minutes to build cosmopolitan.a
This commit is contained in:
Justine Tunney
2020-11-09 15:41:11 -08:00
parent 95bc650be8
commit aea89fe832
70 changed files with 1037 additions and 456 deletions

View File

@@ -42,16 +42,13 @@ _executive:
mov %rdx,%r14
mov %rcx,%r15
call _spawn
call _getstack
mov %rax,%rdi
mov %r12d,%edi
mov %r13,%rsi
mov %r14,%rdx
mov %r15,%rcx
.weak main
mov $main,%esi
mov %r12,%rdx
mov %r13,%rcx
mov %r14,%r8
mov %r15,%r9
call _setstack
mov %eax,%edi
call main
xchg %eax,%edi
call exit
.endfn _executive,weak,hidden
ud2