added a create-project system to assembler, and fixed a couple of parsing bugs

This commit is contained in:
2025-06-20 03:25:28 +01:00
parent f791b05292
commit 42c26d4184
15 changed files with 392 additions and 107 deletions
+5 -14
View File
@@ -1,5 +1,4 @@
include print "./print.dsa"
include fib "./fib.dsa"
dw stack: 0x10000
db string: "An idiot admires complexity, a genius admires simplicity,
@@ -9,23 +8,15 @@ gonna think you're a god cause you made it so complicated nobody can understand
That's how they write journals in Academics, they try to make it so complicated people think you're a genius"
init:
// set up a stack.
ldw stack, bpr
mov bpr, spr
start:
lwi string, rg1
// push variables
push rg1 // string address.
push pcx // return address.
// call
jmp print::print
lli 25, rg0
push rg0
push pcx
jmp fib::fib_n
push rg1
call print::print
pop rg1
hlt