Address Litera I S - Xerox 530 Language And Operations Reference Manual

Table of Contents

Advertisement

Load Location
Counter
16
402
403
404
405
406
407
40B
409
Statement
LDA
CP
BNO
LDA
BIX
STA
B
LPOOL
VAL
VAL+ 10, X
$-2
VAL+ 10, X
$-3
ANS
$+10
4
The literal pool declared above is filled as follows:
(409)
=
-999
(40A) = X ' 101
1
(40B)
=
X ' 10B '
(40C)= X ' 100 '
Assembler Action
The address value VAL is assigned to the literal pool;
indirect addressing is imposed on the instruction and
its address portion is made relative forward; the
instruction is generated as though it were LDA *$+B.
The address value VAL+10 is assigned to the literal
pooli indirect addressing is imposed on the instruction
and its address is made relative forward; the instruc-
tion is generated as though it were CP *$+B,
X.
Generates the instruction; relative addressing is inher-
ent in conditional branch instructions.
VAL+10 was previously established as a literal; indir-
ect addressing is imposed on this instruction; the
instruction is generated as though it were LDA *$+6,
X.
Same as BNO $-2
The address value ANS is assigned to the literal pooli
indirect addressing is imposed on the instruction; the
instruction is generated as though it were STA *$+5.
Same as BNO
$ -2
Declares a literal pool of 4 words beginning at this
location.
Subsequ,ent literals would require another literal pool declaration.
where
label
is any valid symbol.
Use of a label is op-
tional. When present, it is assigned the current
value of the execution location counter and iden-
tifies the first word of the literal pool.
Both
location counters are incremented by the number
of words in the litera I poo
I.
k
is either an absolute previously defined expres-
sion, an integer constant, or is absent. k must
not be a literal.
If the value k is specified in the argument field, the assem-
bler is directed by LPOOL to reserve k memory- locations
for a literal pool at this point in the assembly. Anyaccumu-
lated literals (but no more than k literals) are then immedi-
atelyallocated. If there are more than k literals, the excess
literals will be placed in the next available literal pool. If k
is absent, the assembler is directed to assemble all accumu-
lated I iterals (including indirect address I iterals) at this poi nt.
It is important that t'he programmer establ ish enough I itera I
pools within his program to store all literals specified by his
instructions as well as those address literals imposed by the
assembler. Such literals must be stored within addressing
range of the instructions that reference them.
22
Address Uterals
When the LPOOLdirective is used with a blank argument field,
certain circumstances may result in more memory locations be-
ing allocated for the literal pool than are actually needed.
This occurs because the assembler allocates space in such literal
pools in the definition pass, before forward references have
been defined. When literal pool space isavailablepriortothe
definition point of a forward reference, one location of literal
pool space wi II bel'allocated for each unique symbol so refer-
enced in single-termed expressions. In addition, one location
of I iteral pool space wi II be a 1I0cated for each appearance of a
multi termed expression involving a forward reference, unless
the SLoption(see Chapter B) has been specified. Inthis case,
no assembler-generated literals are allocated for any multi-
term expression involving a forward reference. This allocation
of literal pool storage wi,ll not be performed for any single-
termed expression that has previously appeared as the argu-
ment of an ADRL directive within the addressing range of
the instruction in question, or within a previous LPOOL di-
rective that is in addressing range.
ADDRESS 'LITERALS
When the assembler cannot invoke nonrelative, base-relative,
or self-relative addressing, it invokes indirect addressing
and generates address literals (see "Automatic Addressing"
earlier in this chapter). These address literals require spac.,.

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sigma 3Sigma 2

Table of Contents