aboutsummaryrefslogtreecommitdiff
path: root/include/main_exit.s
blob: a38c5e5ca7eccae687694213ab636a4cc450c025 (plain)
1
2
3
4
5
6
7
8
9
10
.ifndef _main_exit_s_file
_main_exit_s_file:

# exitcode -> | cont (unused, should be 0) |
.thunkcode main_exit
	mov 0x8(%rsi), %rdi # result to syscall exitcode
	mov $0x3c, %rax  # syscall 60
	syscall # exit %rdi

.endif # _main_exit_s_file