diff options
| Commit | c1c2a973906812ff31faf534c4bc384e895cadfe (patch) | |
|---|---|---|
| Author | 2025-03-20 17:08:15 +0200 | |
| Committer | 2025-03-20 17:08:15 +0200 | |
| Files | 54671148b989324071465ba2f3b4f1645fe294e0 /examples/example1.s | |
| tonkobali-main.tar tonkobali-main.tar.gz tonkobali-main.zip | ||
| Parent | bb8c3f02d7c3c318e67575167886de1da123b95a (diff) | |
1 files changed, 14 insertions, 0 deletions
| -rw-r--r-- | examples/example1.s | 14 |
diff --git a/examples/example1.s b/examples/example1.s new file mode 100644 index 0000000..b1e38ed --- /dev/null +++ b/examples/example1.s @@ -0,0 +1,14 @@ +; Assembler produces binary files, containing series of big-endian i64 values + +; Arguments in the form "%NUMBER" signify absolute addresses + +subleq %10, %11, %12 + +; Higher-order instructions convert to a series of subleq instructions +; https://en.wikipedia.org/wiki/One-instruction_set_computer#Synthesized_instructions + +jmp %20 ; subleq %0, %0, %20 + +add %39, %41 ; subleq %39, %0, next_address + ; subleq %0, %41, next_address + ; subleq %0, %0, next_address |
