APPENDIX B CREATING PROCEDURE OF ASSEMBLY SOURCE FILE (Sub tool chain)
248
EPSON
S5U1C88000C MANUAL II
WORKBENCH/DEV TOOLS/OLD ASSEMBLER
Name:
DW
..... Reserve/constant setting of the word unit data area
Format 1:
DW <expression> {,<expression>}*
Format 2:
DW <expression> (<numeric expression>) {,<expression> (<numeric expression>)}*
Format 3:
DW [<numeric expression>] {,[<numeric expression>]}*
Functions:
This instruction is used to reserve the word (2 bytes) unit data area and to set the constant. The setting
of constants are done according to a string of numeric values delimited by a comma or the specifica-
tion for the repeat number. The parameters for this instruction can be described over several lines.
Further when this instruction is used, it should be described within the DATA (RAM) area when
reserving data area, and within the CODE (ROM) area when setting constant. The code generation
rules for each format are as follows.
• Format 1
This format defines the optional constant as the optional number of object codes in word (2 bytes)
units and multiple expressions can be specified for an operand field. The expression is handled as a
long word constant value or symbol value and when multiple specifications are made, the object
codes are generated in the order of specification.
• Format 2
This format repeat defines the optional constant in word units and sets the repeat number in a
<numeric expression> enclosed by parentheses.
• Format 3
This format reserves the area for the number of words that have been assigned by the <numeric
expression> enclosed by brackets. The code generated within the object at this time is 0.
Integer numeric constants, character constants and symbols can be used as the expressions for formats
1 and 2. When the expression has a relocatable quality, the logical address of the location where the
concerned symbol has been allocated is rearranged during linking. The value of the expression must
also be within the range of -32766 to 65535. When an operation result is outside the above range, it
will be made an error and the value of the lower 2 bytes will be made the evaluation value. Each
format can be premixed for one instruction.
Examples:
array:
dw [10]
;
Reserves 10 word size area
external func1,func2,func3,func4,func5
jmptbl:
dw func1,func2,func3,func4,func5
;
Jump table of the functions
Related items:
DB, DL