We're looking for your comments on how to best organize the wiki's content.
Assembly language syntax
Like any language, each assembler can have its own syntax. This page documents what we see Notch doing, so that other developers can make compatible tools.
- Comments begin with a semicolon (;) and extend to the end of the line.
- Blank lines are ignored.
- Address labels start with a colon (:) and consist of a single word (legal characters unclear, but no spaces)
- The resulting labels appear as normal, unqualified arguments, implying that registers (
A, B, C, X, Y, Z, I, J, SP, PC, EX) and register access keywords (
POP, PEEK, PUSH) are reserved words.
- Instructions are indented; conditionally jumped instructions are indented twice. (These may be optional and for user-clarity only)
- Brackets () indicate indirection.
- Number bases are indicated C-style:
0xprefix indicates hexadecimal numbers.
- Other numbers are in decimal.
- Arguments are comma (,) separated
- Default assembly origin seems to be
- No label equate has been shown yet (a label that is equal to a user-defined value).
- The pseudo-op
DATin the screenshot can take words or strings, which are apparently loaded one-character-per-word.
No relocatable/linkable object formats are defined yet (but it isn't hard).
 See also
- DCPU-16 1.7 specification (Copyright 2012 Mojang)