Sorry, pushed unsinifhs code...

This commit is contained in:
xolatile 2024-07-16 11:14:35 -04:00
parent 51e48cd82b
commit ccc02a33b3
2 changed files with 42 additions and 4 deletions

View File

@ -324,6 +324,13 @@ static void build_move (size_index size,
input_at ((to == REG) && (from == REL), D32, source);
}
static void build_call (type_index from,
next source) {
// call
(void) from;
(void) source;
}
static void assemble_clean_up (void) {
if (assemble_clean_up_queued == 0) {
return;
@ -418,6 +425,7 @@ void assemble (next count,
index += 5;
} else if (array [index] == CALL) {
build_call (array [index + 1], array [index + 2]);
index += 2;
} else {
return;
}

View File

@ -6,34 +6,64 @@ segment readable executable
entry main
heyo: mov eax, 1
heyo:
nop
mov eax, 1
nop
mov edi, 1
nop
mov esi, h
nop
mov edx, 12
nop
syscall
nop
call meme
nop
ret
cyaa: mov eax, 1
cyaa:
nop
mov eax, 1
nop
mov edi, 1
nop
mov esi, c
nop
mov edx, 12
nop
syscall
nop
ret
main: call heyo
main:
nop
call heyo
nop
call cyaa
nop
mov eax, 60
nop
mov edi, 60
nop
syscall
meme: mov eax, 1
meme:
nop
mov eax, 1
nop
mov edi, 1
nop
mov esi, m
nop
mov edx, 12
nop
syscall
nop
ret
nop
segment readable writable
h: db "Heyo world!", 10