immediate syntax
This commit is contained in:
parent
8b5854c43b
commit
d6a02946cc
8
uxntal.1
8
uxntal.1
|
@ -120,7 +120,7 @@ The program counter (\fIpc\fP) is updated when \fIbool\fP is non-zero. When \fIx
|
||||||
.SS JSR
|
.SS JSR
|
||||||
( x -- [pc+1*] )
|
( x -- [pc+1*] )
|
||||||
|
|
||||||
Store the next address to execute before unconditionally updating the program counter (\fIpc\fP). This instruction is usually used to invoke subroutines, which use the \fBJMP2r\fP to return.
|
Store the next address to execute before unconditionally updating the program counter (\fIpc\fP). This instruction is usually used to invoke subroutines, which use the \fBJMP2r\fP to return. When \fIx\fP is a byte, it is treated as relative (\fBpc += x\fP) and when \fIx\fP is a short it is treated as absolute (\fBpc = x\fP).
|
||||||
|
|
||||||
.SS STH
|
.SS STH
|
||||||
( x -- [x] )
|
( x -- [x] )
|
||||||
|
@ -241,6 +241,12 @@ The "immediate jump" instructions are produced by the assembler. They interpret
|
||||||
|
|
||||||
(The instruction pointer will be moved forward 2 bytes, past the relative address.)
|
(The instruction pointer will be moved forward 2 bytes, past the relative address.)
|
||||||
|
|
||||||
|
These instructions are created by the assembler from special syntax:
|
||||||
|
|
||||||
|
\fB!dest\fP produces \fBJMI wx yz\fP
|
||||||
|
\fB?dest\fP produces \fBJCI wx yz\fP
|
||||||
|
\fBdest\fP produces \fBJSI wx yz\fP (assuming \fBdest\fP is not a macro or reserved)
|
||||||
|
|
||||||
.SS LIT, LIT2, LITr, and LIT2r
|
.SS LIT, LIT2, LITr, and LIT2r
|
||||||
|
|
||||||
The "literal" instructions are used to push new data onto the stacks. They interpret the next 1-2 bytes of the ROM (\fIwx\fP, \fIwxyz\fP) as data and push it onto the corresponding stack:
|
The "literal" instructions are used to push new data onto the stacks. They interpret the next 1-2 bytes of the ROM (\fIwx\fP, \fIwxyz\fP) as data and push it onto the corresponding stack:
|
||||||
|
|
Loading…
Reference in New Issue