! is the line comment character.
You can use ; instead of a newline to separate statements.
The Z8000 has sixteen 16 bit registers, numbered 0 to 15. You can refer to different sized groups of registers by register number, with the prefix r for 16 bit registers, rr for 32 bit registers and rq for 64 bit registers. You can also refer to the contents of the first eight (of the sixteen 16 bit registers) by bytes. They are named rln and rhn.
byte registers rl0 rh0 rl1 rh1 rl2 rh2 rl3 rh3 rl4 rh4 rl5 rh5 rl6 rh6 rl7 rh7 word registers r0 r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15 long word registers rr0 rr2 rr4 rr6 rr8 rr10 rr12 rr14 quad word registers rq0 rq4 rq8 rq12 |
as understands the following addressing modes for the Z8000:
Register direct: 8bit, 16bit, 32bit, and 64bit registers.
Indirect register: @rrn in segmented mode, @rn in unsegmented mode.
Direct: the 16 bit or 24 bit address (depending on whether the assembler is in segmented or unsegmented mode) of the operand is in the instruction.
Indexed: the 16 or 24 bit address is added to the 16 bit register to produce the final address in memory of the operand.
Base Address: the 16 or 24 bit register is added to the 16 bit sign extended immediate displacement to produce the final address in memory of the operand.
Base Index: the 16 or 24 bit register rn or rrn is added to the sign extended 16 bit index register rm to produce the final address in memory of the operand.
Immediate data xx.