diff options
| author | Christian Cunningham <cc@localhost> | 2024-07-14 10:52:51 -0700 | 
|---|---|---|
| committer | Christian Cunningham <cc@localhost> | 2024-07-14 10:52:51 -0700 | 
| commit | 5b0f04f0c5d406def1acbcdbcc114e9b4bf5c7da (patch) | |
| tree | e75b1ef3878d279ce50baaaaa43a993e05d90474 /main.asm | |
| parent | f4c8ec9028f19fe334ecd4ae49521011fcdba012 (diff) | |
Double Linked List
Diffstat (limited to 'main.asm')
| -rw-r--r-- | main.asm | 43 | 
1 files changed, 43 insertions, 0 deletions
@@ -110,6 +110,49 @@ _main:  	pop	rax  	lln_free +	dll_alloc +	push	rax +	mov	rbx,	rax +	mov	r12,	0xDEADBEEF +	dll_push	rbx,	r12 +	push rax +	mov	rbx,	[rsp+8] +	mov	r12,	0xCAFEBABE +	dll_push	rbx,	r12 +	push	rax + +	mov	rbx,	[rsp+16] + +	mov	rax,	rbx +	mov	rax,	[rax + dll_value] +	REGD	rax + +	mov	rax,	rbx +	dll_seek +	mov	rax,	[rax + dll_value] +	REGD	rax + +	mov	rax,	rbx +	dll_seek +	dll_seek +	mov	rax,	[rax + dll_value] +	REGD	rax + +	mov	rax,	rbx +	dll_end +	mov	rax,	[rax + dll_value] +	REGD	rax + +	pop	rax +	pop	rax +	pop	rax +	dll_end +.free_loop: +	mov	rbx,	[rax + dll_prev] +	dll_free +	mov	rax,	rbx +	cmp	rbx,	0 +	jne	.free_loop  	exit_prog  | 
