mirror of
https://github.com/hmaxnl/based.git
synced 2025-04-04 22:51:27 +02:00
17 lines
422 B
ArmAsm
Executable File
17 lines
422 B
ArmAsm
Executable File
//#include "../syscalls.h"
|
|
|
|
.globl _start
|
|
.globl rt_unix_start
|
|
|
|
.text
|
|
|
|
// Start point unix.
|
|
_start:
|
|
xor %rbp, %rbp // Clear stack frame pointer
|
|
|
|
mov (%rsp), %rdi // Movq argc to rdi
|
|
lea 0x8(%rsp), %rsi // Get the argv address
|
|
lea 16(%rsp,%rdi,8), %rdx // Get the envp address
|
|
|
|
call rt_unix_start // Start c function
|
|
hlt // Halt if the lib or app does not call the exit function. |