undar-lang/test/hello.asm.lisp

11 lines
370 B
Common Lisp

((code
(label main
(load-immediate $0 &terminal-namespace) ; load terminal namespace
(load-immediate $1 &hello-str) ; load hello string ptr
(string-length $2 $1) ; get length to write to stdout
(syscall DEVICE-WRITE $0 $1 $2) ; do the write syscall
(halt))) ; done
(data
(label terminal-namespace "/dev/term/0")
(label hello-str "nuqneH 'u'?\n")))