This commit is contained in:
nub31
2025-06-26 15:15:01 +02:00
parent 9f20e71740
commit 3d06f40516
5 changed files with 41 additions and 18 deletions

20
src/runtime/targets/x64.s Normal file
View File

@@ -0,0 +1,20 @@
.intel_syntax noprefix
.text
.globl nub_write_string
# void nub_write_string(const char* str)
nub_write_string:
push rdi
call nub_cstring_length
mov rdx, rax
pop rsi
mov rax, 1
mov rdi, 1
syscall
.text
.globl nub_exit
# void nub_exit(int code)
nub_exit:
mov rax, 60
syscall