diff options
| author | krolxon <krolyxon@tutanota.com> | 2026-01-08 19:21:43 +0530 |
|---|---|---|
| committer | krolxon <krolyxon@tutanota.com> | 2026-01-08 19:21:43 +0530 |
| commit | 467ec78e894c8184144bfac039dc7d780abbd050 (patch) | |
| tree | 048d9f8c4e43a88993f0c1f4e15d92df612dc46b /README.md | |
| parent | 4667df1425e3414e163c63754d01d9b0b3a2f488 (diff) | |
add SYS instruction
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 17 |
1 files changed, 14 insertions, 3 deletions
@@ -20,6 +20,7 @@ | MUL | mul r1, r2 | | DIV | div r1, r2 | | CALL | call \<label\> | +| SYS | sys \<syscall_no\> | | HLT (Halt) | hlt | @@ -33,6 +34,7 @@ | PC | 16-bit | Program Counter | | SP | 16-bit | Stack pointer | + ## Flags | Flag | Description | | ----- | ------------ | @@ -40,6 +42,14 @@ | C | Carry/Borrow | +## Syscalls +| Imm | Meaning | +| --- | ------- | +| 0 | Exit Program | +| 1 | Print register A as integer | +| 2 | Print register A as ASCII char | + + # Usage ```bash cargo run -- --f <examples/filename.asc> @@ -49,11 +59,12 @@ cargo run -- --f <examples/filename.asc> - [x] Assembler - [x] Lexer/Tokenizer - [x] Add label support (supporting JMP/JZ/JNZ) -- [ ] Add instructions +- [x] Add instructions - [x] CMP - [x] MUL - [x] DIV - [x] CALL - [x] RET -- [ ] Error handling -- [ ] Build Debugger + - [x] SYS +- [ ] Better Error handling +- [ ] TUI Debugger |
