Goto; Gen Directive; Gen1 Directive; Gen2 Directive - Xerox 530 Language And Operations Reference Manual

Table of Contents

Advertisement

x
is an expression that must be evaluated as an
absolute value, if present. A nonzero abso lute
value s.pecifies post-indexing. A 0 (or a blank)
specifies that post-indexing is not to be performed.
b
is an expression that must be evaluated I ike X.
A
nonzero absolute value specifies pre-indexing.
A zero (or a blank) specifies that pre-indexing is
not to be performed.
o
is any admissible address expression.
The absence of one of the items in the argument field must
be indicated by successive commas (see Example 21).
GE~l
and GEN2 are useful in writing procedures (see
Chapter 7).
Automatic addressing conditions for instructions produced
by GE N
1
are the same as described in Chapter
4
under
"Addressing" •
The argument address for GEN2 must comply with the self-
relative addressing requirements of Class 2 instructions;
that is, the address must be within the self-relative address-
ing range of the instruction ($-256 to $+255).
Example
19.
GE N Directive
X
EQU
-1
Y
EQU
1
GEN,8,;
8,16
5,Y,X
Produces:
Hex. Binary
0501
1
QOOOIO 1 0 1100001000 11
0
7
15
FFFF 1111111111111111illJ]
B
EQU
5
0
7
15
GEN, B,
i
16-B
3,15
Produces:
1 80F
LQQQ
11 100dfOOooUillJ
0
7
15
Example 20. GE N 1 Directive
GENl
STA
EQU
GEN1
8,0,0, ;
NUM
X'E'
Generates the equivalent
of the symbolic instruc-
tion LDA NUM
11000100001 N UM
o
7
STA, 1, "
i
Generates the equiva lent
ANS
of the symbolic instruc-
tion STA
*
ANS
1111010JOoIANS
o
7
34
Extended Symbol Di rectives
J
I~
15
(
Example 21. GEN2 Directive
BAN
GOTO
EQU
GEN2
X ' 3T
BAN, $-3 Produces:
Clo$$ 2
Bon
instruction
liE
10
1)1\111111101
I
o
6
15
Conditional Branch
The GOTO directive enables the user to conditiona lIy
alter the sequence in which statements are assembled. The
GOTO directive has the form
Label
Command
Argument
GOTO[,
k)
label) [,labeI2""~ label
n
)
where
k
is an absolute, evaluatable (no forward or exter-
nal references), integer-valued expression.
If k
is omitted, J is assumed.
labeli
is a forward reference. The labels must be
nonloca
I
symbols if the GOTO directive appears
in a nonlocal symbol region.
A GOTO statement is executed at the time it is encoun-
tered during the assembly. Extended Symbol evaluates the
expression k (if present) and resumes assembly at the line
that contains a label corresponding to the kth label in the
GOTO argument field. The labels must refer to I ines that
follow the GOTO directive. If the va lue of
k
is not
be-
tween J and nr Extended Symbol resumes assembly at the
statement immediately following the GOTO directIve. An
error message is given if the value of k is greater than n.
A label that is normally ignored by the assembler (i. e., a
label on END, FIN, LOCAL, PAGE, PROC, PEND,
TITLE, or another GOTO statement) will be recognized
if it is the target (kth) label of a GOTO search.
A statement skipped as the result of a GOTO appears on
the assembly listing in symbolic form; the absence of gen-
erated code indicates that it has been ignored.
When Extended Symbo
I
encounters the first of a logica
I
pair
of directives t while in the skipping mode, it suspends its
search for the label unti
I
the other member of the pair is en-
countered. Then it continues the search. Thus, whi Ie in
skipping mode, Extended Symbol does not recogni ze labels
that are within procedure definitions or iteration loops. It is
notpossibJe, therefore, towriteaGOTOdirectivethat might
branch into a procedure definition or a DO/FIN loop. tt
t Certain directives must occur in pairs: PROC/PEN D and
DO/FIN.
ttIt is legal, however, to terminate a DO loop by branch-
ing past the associated FIN.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sigma 3Sigma 2

Table of Contents