libk  Diff

Differences From Artifact [3c036595d7]:

To Artifact [a74c88489c]:


1
2
3
4
5
6
7
8
9
10
..
57
58
59
60
61
62
63
64
65
66
67
; vim: ft=nasm
bits 64
%include "../arch/posix/x86.lin.64.s"
global _start:function
extern _boot
extern entry

_start:
	mov rbp, 0 ; zero the stack base ptr.
	; attempted fix for a difficult-to-
................................................................................
	; regardless of the size of the
	; return value of main(), _boot always
	; returns the system word length.

	mov sys.reg.1, sys.reg.ret ; fill in
	; the return value as exit's argument

	mov sys.reg.0, sys.exit ; set %rax to
	; the syscall number of exit

	sys.call ; invoke the kernel


|







 







|



1
2
3
4
5
6
7
8
9
10
..
57
58
59
60
61
62
63
64
65
66
67
; vim: ft=nasm
bits 64
%include "syscall.s"
global _start:function
extern _boot
extern entry

_start:
	mov rbp, 0 ; zero the stack base ptr.
	; attempted fix for a difficult-to-
................................................................................
	; regardless of the size of the
	; return value of main(), _boot always
	; returns the system word length.

	mov sys.reg.1, sys.reg.ret ; fill in
	; the return value as exit's argument

	mov sys.reg.0, 60 ; set %rax to
	; the syscall number of exit

	sys.call ; invoke the kernel