3.6 Instruction Format Field Characteristics
Instruction format definitions are specified in terms of fields, where each field includes one or more contiguous bit positions of the instruction word.
Field characteristics include the following:
b. Variable fields (identified by type designator, V)
c. Unused (don’t care) fields (identified by type designator,
X)
3. Position. Fields are listed in sequence from left to right. The most significant bit of the first field occupies the most significant bit position in the word. In field listings, commas (,) are used to separate successive fields. Two commas with no field listing between them indicate that a variable field of the word has been skipped. The notation [n] can be used to avoid entry of a long series of commas when a number of consecutive variable fields are to be skipped. [n] means skip to the nth field of the instruction format. (In this case, constant and don’t care fields as well as variable fields are counted).
4. Variable Field Attributes. These are attributes to be assigned to any constant substituted into the field at assembly time. They include the following:
b. Page address attribute ($)
c. Overlay attribute (@)
6. Default Base Designator Attribute. When no default value
is listed, a default base designator attribute (e.g. H#, D#) can be specified
for a field. This default designation governs if a numerical constant without
a base designator attribute is substituted into the field. If the variable
field substitution value includes a base designator attribute, this overrides
the default base designator attribute.
Modifiers are special characters which are appended to constants or expressions to modify their evaluation. Modifiers can also be used as variable field attributes which modify the values of constants substituted into the fields at assembly time. Modifier characters are listed as follows:
Character | Modification | Example |
< | PC-relative (When a PC-relative expression is evaluated, it is converted into a positive or negative displacement with respect to the program counter which points to the location following the one containing the microinstruction being evaluated. A negative displacement is represented in two’s complement form. For a relocatable symbol, the evaluation is performed by the linker phase.) | 00A1< at location 00A4 yields negative displacement FFFC (-4) obtained by subtracting 00A5 (the PC value) from 00A1 |
* | Inversion (one’s complementation) | B#101* = B#010 |
- | Negation (two’s complementation) | B#101- = B#011 |
: | Truncation (If implicit width of constant is greater than explicit width or is greater than width of variable field into which it is substituted, discard bits, starting at left end of constant, as required to produce residue matching explicit width or variable field width) | 3B#1010: = B#010 |
% | Right justification (If implicit width of constant is less than explicit width or is less than width of variable field into which it is being substituted, add leading zeros as required to match explicit width or variable field width) | 5B#1010% = B#01010 |
3.8 Special Instruction Field Attributes
There are two special instruction field attributes: the page address attribute ($) and the overlay attribute (@).
Appending the page address attribute ($) to an instruction field specifies that the field is to be interpreted as an address within the currently addressed page. The width of the field to which the page attribute is appended implies the number of locations on a page.
For example, if the field width is 8 bits, then the page capacity must be 256 locations. When a constant of greater width than a page address field is substituted into that field, two operations are automatically performed. The constant is left truncated to fit the field. The truncated bits are compared with the corresponding bits of the current address to determine whether a page coundary has been crossed. If so, a page address error is generated.
Instruction formats having unused (don’t care) fields can be combined (overlaid) if the variable or constant field bits of each format are overlaid only on don’t care bits of the other format.
In special cases, a valid instruction may be formed by overlaying care bits from one format with care bits of another format. In order to allow this, the overlay attribute must be appended to the field whose care bits are to be used in the overlay.
When a relocatable program module is assembled, an address is assigned to every microinstruction word. However, this address value represents an offset within the module rather than an absolute memory address location. At link time, each instruction word from a relocatable module is relocated at an absolute memory address. Thus, symbolic address labels specified in the instruction/data source statements of an assembly-phase source program for a relocatable module represent relocatable values rather than absolute memory address values. It follows from this that any expression containing a symbolic address label is also a relocatable quantity.
Symbolic address labels provide the means for linking separately assembled modules together. A branch instruction in module n to a symbolic address in module m constitutes a link from module n to module m. In order to allow such a link, the symbolic address label must be declared as an EXTRN symbol in module n and must be declared as a PUBLIC symbol in module m. The declaration of a symbol as EXTRN informs the assembly-phase program that the symbol is defined in another source program and that any expression containing the symbol must be passed to the linker for final evaluation. The use of PUBLIC symbol declarations identifies the symbols that must be passed to the linker for use in other modules.
The linkages which involve symbolic address labels establish program sequencing links. Constant names and set-parameter names can also be declared as PUBLIC symbols. This makes the associated values accessible at link time to other modules in which they are declared as EXTRN symbols. The disadvantage to this type of linkage is that expressions containing the EXTRN symbols cannot be evaluated completely until link time.
Depending upon the statement type, a statement may include up to four type of fields. Listed in the order in which they appear, if used, these field types are summarized in Table 3-6.
In general, statements that are not comment statements belong to one of two categories:
2. Instruction or data source statements: These statements specify
operations to be executed by the target machine or data for use by the
target machine. These instructions appear only in the assembly-phase source
program. The assembly-phase program converts the into object code.
The statement operator must always be separated from the operand fields by a blank (space) character or a TAB character.
Successive operand fields must be separated by commas.
The comment field of a statement must always begin with a semi-colon (;). As this implies, a separate comment statement starts with a semi-colon.
Statements whose operator field contains a directive symbol are designated in terms of that directive. Thus, for example, a DEF statement is a statement containing the DEF directive symbol in its operator field. The only statements which do not contain a directive symbol in the operator field are MACRO calls (in which the MACRO name is the operator symbol) and formatted instruction statements (in which a format name is the operator symbol).
Certain statements, if too long to fit on a single line, can be completed on one or more continuation lines. A continuation line is identified by a slash (/) character in the first non-blank character position of the line. When a continuation is used, each line must end with a field delimiter or with a commend field word. DEF, SUB, FF, and formatted instruction statements can be completed on continuation lines.
The only format requirements for comment statements are that they begin with a semicolon (;) and that they be completed on a single line.
Table 3-6. Statement Field Types
Field Type | Description |
Symbol | The symbol specified in this field assumes a functional identity as summarized in Table 3-2. Depending upon the statement type, the symbol field may be mandatory, optional, or not used. |
Operator | This field contains a symbol which has an operator identity. Symbols having operator identity include the directive symbol set, MACRO names (which are the operator symbols in MACRO call statements), and format names (which are the operator symbols in formatted instruction statements). To be processed by the assembler definition-phase or assembly phase program, a statement must contain an operator field. Formatted instruction statements may contain more than one format name; i.e. more than one operator field. Other types of statements are limited to a single operator field. |
Operand | These fields contain the operands required for the operation specified by the operator field. Depending upon the type of statement, the operand field may be mandatory, optional, or not used. |
Comment | This field contains information to be printed on program listings. It is not processed by the assembler programs. Any type of statement may have a comment field. A statement that has only a comment field is called a comment statement. |
Chapter 4: Source Program Statements
4.1 Introduction
This chapter contains descriptions and formats of all of the types of statements, other than comment statements, that can be used in assembler source programs.
Statement types are divided into the categories listed in Table 4-1.
Each of the primary paragraphs which follows contains the descriptions of the statement types within one of the categories defined in Table 4-1 or of one of the statements within the miscellaneous category. Table 4-2 presents an alphabetical list of statement types with paragraph references for each statement type.
Table 4-1. Statement Categories
Category | Description |
Definition Statements | This category includes the statements required to define instruction word length, instruction formats, and constants. |
Print Control Statements | This category includes statements which specify the scope and format of information printed out by the definition phase or assembly phase program. |
Conditional Assembly Statements | These are statements which make processing of associated source statements conditional upon the satisfaction of a specified condition |
MACRO Definition and Call Statements | These are statements used to define and call MACROs |
Assembly Program Counter Control Statements | These are statements which change the current value of the assembly program counter; that is, the counter whose value determines the memory address assigned to each machine instruction. |
Instruction/Data Source Statements | These are the statements which contain the symbolic instruction coding that is converted into machine code by the assembler-phase program. |
Relocation Definition Statements | This category includes the statement that specifies that a source program contains relocatable address and statements which list symbols involved in linkages between relocatable modules. |
Miscellaneous | Statements in this category are the INCLUDE,
MAP, and END statements.
An INCLUDE statement specified a secondary source file whose statements are to be processed by the assembler program before the next statement in the primary source program is processed. A MAP statement causes the generation and listing of an entry point map. An END statement terminates a source program. |
Table 4-2. Alphabetical List of Statement Types
Statement Type | Category | Comment |
ALIGN | Counter Control | Assembly Phase Only |
DATA | Inst./Data Source | Assembly Phase Only |
DEF | Definition | Definition Phase Only |
DUP | Inst./Data Source | |
EJECT | Print Control | |
ELSE | Conditional Assembly | |
END | Miscellaneous | |
ENDIF | Conditional Assembly | |
ENDM | MACRO | |
EQU | Definition | |
EXITM | MACRO | |
EXTRN | Relocation Definition | Assembly Phase Only |
FF | Inst./Data Source | Assembly Phase Only |
FORM | Print Control | Assembly Phase Only |
FORMAT.INST | Inst./Data Source | Assembly Phase Only |
HEAD | Print Control | Assembly Phase Only |
IF | Conditional Assembly | |
IFC | Conditional Assembly | Assembly Phase Only |
IFD | Conditional Assembly | Assembly Phase Only |
IFNC | Conditional Assembly | Assembly Phase Only |
IFND | Conditional Assembly | Assembly Phase Only |
INCLUDE | Miscellaneous | |
LINES | Print Control | |
LIST | Print Control | |
LOCAL | MACRO | |
MACRO | MACRO | |
MACRO Call | MACRO | Assembly Phase Only |
MAP | Miscellaneous | Assembly Phase Only |
NOLIST | Print Control | |
ORG | Counter Control | Assembly Phase Only |
PUBLIC | Relocation Definition | Assembly Phase Only |
.REL | Relocation Definition | Assembly Phase Only |
RES | Counter Control | Assembly Phase Only |
SET | Definition | |
SPACE | Print Control | |
SUB | Definition | Definition Phase Only |
TAB | Print Control | |
TITLE | Print Control | |
TITLE2 | Print Control | |
WIDTH | Print Control | |
WORD | Definition |
The WORD statement specifies the nubmer of bits in the microword. It must appear in the definition phase source program prior to the first DEF statement.
The format of the WORD statement is:
An EQU statement equates a constant name to an expression.
The format of the EQU statement is:
This equates the symbol, R15, to the hexadecimal value, F. Wherever
R15 appears in the operand field of a statement, the assembler will substitute
the value F (hexadecimal) when the field is evaluated.
A SET statement specifies a value to be assigned to a parameter name until a later SET statement assigns another value to that paramter name.
The format of a SET statement is:
This sets the symbol DBUF to the hexadecimal value 0800, until superceded by another SET statement with DBUF in the symbol field.
As long as this statement is not superceded, wherever DBUF appears in the operand field of a statement, the assembler will substitute the value 0800 (hexadecimal) when the field is evaluated.
A DEF statement associates an instruction format name with an instruction format. The instruction format is defined as a set of fields. The order in which the fields are listed defines their position in the microinstruction word. Fields may be variable, constant, or don’t care.
A variable field is specified as follows:
(length)V{attributes}{default value}{default value modifiers}
or
(length)V{attributes}{default base designator attribute}
where:
V specifies a variable field,
Optional attributes are as defined in paragraphs 3.6 and 3.7,
Optional default value is a numerical constant, an expression, or a don’t care (X),
Optional default value modifiers are from Table 3-5,
Optional default base designator attributes are H#, D#, Q#, B#.
A don’t care field is specified as follows:
X specifies the don’t care field type
The sum of the field lengths must equal the microword length specified in the WORD statement.
The maximum allowable number of fields in a DEF statement is 64. The maximum length of a variable or constant field is 31 bits. There is no restriction on the length of a don’t care field. (NOTE: WinTim32 has no theoretical limit on the number of fields in a DEF statement).
The format of a DEF statement is as follows:
8VH#FF = 8-bit variable field with hexadecimal FF default value
16VH#X = 16-bit variable field with hexadecimal don’t care default value
1VQ#4 = 1-bit variable field with octal 4 default value
4X = 4-bit field with don’t care default value
2VQ#5 = 2-bit variable field with octal 5 default value
1B#1 = 1-bit binary constant field with a value of 1
1X = 1-bit field with don’t care default value
OPR.IN = instruction sub-format name (see SUB statement example below).
8X = 8-bit field with don’t care default value
3V:B#000 = 3-bit field with left-truncate attribute and binary 000 default value
3VB#010 = 3-bit variable field with binary 010 default value.
1VB#1 = 1-bit variable field with binary 1 default value
1X = 1-bit field with don’t care default value
A SUB statement defines a set of contiguous fields of an instruction format and associates an instruction sub-format name with that definition. It is exactly like a DEF statement except that it does not define all of the fields of the instruction. The set of fields defined by a SUB statement is included in a DEF statement by entering the instruction sub-format name in the DEF statement (See Example 2 above).
3VQ#0 = 3-bit variable field with octal 0 default value
4.3.1 LIST and NOLIST Statements
A LIST statement turns on a specified set of listing parameters while a NOLIST statement turns off a specified set of listing parameters. The parameters controlled by LIST and NOLIST statements and the default values of these parameters are summarized in Table 4-3. LIST and NOLIST statements can be used at any desired points in the source program to reverse the current status of any of the parameters.
The form of a LIST statement is:
The statement:
Parameter | Description | Default State |
A | List addresses on every line rather than just on lines where object code is listed. | Off |
B | List formatted object code in block following end of source code listing if S is on*. | Off |
E | List source lines with errors at user’s console as well as in output listing. | Off for def, On for assem |
F | List formatted object code to left of source code if S is on. | Off |
I | List instructions not assembled because of conditional assembly decisions. | Off |
M | In MACRO expansions, list all statements (except those not listed because option I is off.) When M is off only MACRO expansion statements which produce code are listed. | On |
Q | List addresses in octal format rather than hexadecimal format. | Off |
R | Create reference file to support later editing of symbolic code from list file using separate TIM_PATCH program. | Off |
S | List text (when this is off no source or object code elements are listed). | On |
T | List symbol table | On |
W | Wrap-around to next line when line exceeds maximum width (if off, lines that exceed maximum width are truncated). | Off |
X | List cross reference table (overrides T) | Off |
* If F and B are both off, object code is not listed. If F and B are both on, object code is listed both to the left of the source code and in the block following the end of the source code listing.
LIST options T and X control symbol listings which appear at the end of a listing file if selected. The symbol table, selected by LIST option T, is an alphanumeric listing of the symbols appearing in the file along with type and value information.
The cross reference table, selected by LIST option X, contains the same information as the symbol table and, in addition, it provides a cross reference to the source code listing lines on which each symbol appears.
4.3.2 TITLE and TITLE2 Statements
These statements are used to specify a user title to be printed on each page of the program listing below the listing title line. The listing title line, which is not subject to user modification, has the following format:
TIM Listing: srcfile (dat/time) page #
where:
A user title of up to 100 characters long can be specified by:
TITLE2 title2 text
title2 text includes the remaining up to 50 characters of the title.
NOTE: A comma (,) is interpreted as a delimiter in the TITLE statement and thus the title text cannot include a comma.
If a file does not contain a TITLE statemtn, no user title is printed.
A HEAD statement specifies headings for object code. These headings are printed above theobject code on each page of the listing when the LIST F parameter is on. The format of the HEAD statement is:
The FORM statement defines the object code listing format. This can be any desired sequence of binary, octal, and hexadecimal digits with blanks embedded at desired positions. The only restriction is that the total width in bits of the specified sequence of digits must equal the defined microword width.
The format of each digit in the sequence is indicated by a numeral which specifies the number of bits in the digit. Each blank is indicated by a B.
The format of the FORM statement is:
The LINES statement specifies the maximum nubmer of lines to be printed on a page of the program listing The format of the LINES statement is:
A SPACE statement specifies the insertion of one or more blank lines ahead of the listing of the next statement. The format of a SPACE statement is:
An EJECT statement causes the listing form to be advanced to the top of the next page. The format of the EJECT statement is:
The WIDTH statement specifies the number of columns per line in the program listing. In the case of a definition-phase program, any line that exceeds this width is truncated. In the case of an assembly-phase program, any line that exceeds this width is either wrapped around to the next line (if the LIST W parameter is on) or is truncated (if the W parameter is off).
The format of the WIDTH statement is:
When a TAB character is found in a MACRO body statement, it is replaced by n SPACE characters. The print format for expanded MACROs whose body statements contain TAB characters is thus affected by the value assigned to n.
The TAB statement specifies the number of SPACE characters, n, to be substituted for each TAB character found in a MACRO body statement. In the absence of a TAB statement, the default value of n is 4. Using the TAB statement, n can be set to any decimal value from 1 to 10.
A TAB statement entered in the definition-phase source program governs the MACRO definitions which follow it in that program but has no effect on assembly-phase source programs using the associated definition file. Thus, to change n from the default value for MACRO definitions contained in an assembly-phase source program, a TAB statement must appear in that program.
In the event that a definition-phase or assembly-phase source program contains more than one TAB statement, then the TAB statement which most closely precedes any MACRO definition governs for that MACRO definition.
The format of the TAB statement is:
Conditional assembly statements are used to assemble a group of statements only if some specified condition is satisfied or to assemble one group of statements if a specified condition is satisfied and an alternate group of statements if that condition is not satisfied.
Conditional assembly control statements include the IF-type statement, the ELSE statement, and the ENDIF statement. A conditional assembly sequence always begins with an IF-type statement and ends with an ENDIF statement.
The general format of an IF-type .. ENDIF dequence is:
statement
.
.
statement
ENDIF
statement
.
.
statement
ELSE
statement
.
.
statement
ENDIF
The format of an IF statement is:
If any non-zero value is obtained, then, by definition, the IF condition is satisfied. If zero is obtained, then the IF condition is not satisfied.
The format of an IFC statement is:
start and end are optional pointers to character positions in string1 and string2.
The format of an IFNC statement is identical to that of an IFC statement except that IFNC replaces IFC. By definition, an IFNC statement is satisfied if at least one of the characters of string1 that is compared with a string2 character differs from the string2 character.
IFC and IFNC statements are useful as MACRO body statements in which at least one of the strings is specified as a formal MACRO parameter. In this usage, the actual string used in the comparison is the formal parameter substitute passed by the MACRO call statement.
IFD and IFND statements are used to make assembly conditional upon whether or not a specified symbol has been defined prior to the IFD or IFND statement.
The format of an IFD statement is:
The format of an IFND statement is:
4.5 Macro Definition and Call Statements
A MACRO definition opens with a MACRO statement and closes with an ENDM statement. Optionally, the MACRO statement may be followed by one or more LOCAL statements. Statements between the LOCAL statements and the ENDM statement, or, if no LOCAL statements are required, between the MACRO statement and the ENDM statement, constitute the body of the MACRO.
In general any statements that can appear outside of a MACRO definition in the assembly-phase program can be used as statements in the MACRO body. The one exception to this is that nesting of MACRO definitions is not permitted. However, MACRO calls, including calls to the MACRO being defined, are permitted.
In one important respect the statements used in the body of a MACRO differ from statements used outside of a MACRO. The statements used in the body of the MACRO can contain any of the formal parameters appearing in the MACRO statement. When a MACRO is called, the formal parameters named in the MACRO statement are replaced by actual parameters named in the MACRO call statement or become null if no actual parameters are named in the MACRO call statement.
When a MACRO definition is processed, the body of the MACRO is not assembled but is merely saved for assembly in response to a call to that MACRO. Each time that a MACRO call occurs, the body of the named MACRO is assembled using the actual parameters named in the MACRO call. A formal parameter appearing in a MACRO body statement must be separated from the body text characters by delimiters. The single quotation mark(‘) is used to satisfy this requirement if the formal parameter is not otherwise delimited. For example, if X and Y are formal parameters of a MACRO, then in the body statement:
It follows that the actual parameter substituted for a formal parameter may include delimiters. This requires additional special notation in the MACRO call statement as described in paragraph 4.5.3.
Symbolic address labels can be used in the body of a MACRO. However, each such symbolic address label must be declared in a LOCAL statement in the MACRO definition in order to avoid duplicate label errors being generated in connection with the multiple calls of the MACRO.
Conditional assembly statements can be used in the MACRO body to make the assembly of certain machine instruction source statements contingent upon the passing of a particular actual parameter or upon some other condition. Because the ENDM statement indicates the end of a MACRO definition, another statement must be used to indicate conditional terminations of the MACRO expansion that occur within the MACRO body statement sequence. This other statement is the EXITM statement. When assembled, this statement terminates the MACRO expansion.
A reserved word, NARG, will be set to the number of arguments passed to the MACRO. For an example, see Section 6.7.
Any TAB character found in a MACRO body statement is converted to n space characters, where the default value of n is 4. A TAB statement (paragraph 4.3.9) can set n to any value between 1 and 10.
4.5.2 MACRO Definition Statement Formats
The format of a MACRO statement is:
f1, f2, …, fn are optional formal parameters.
The format of the ENDM statement is:
The format of the EXITM statement is:
The format of a MACRO call is:
s1, s2, …, sn are individually optional actual parameters substituted respectively for the formal parameters f1, f2, …, fn named in the MACRO definition.
As noted in paragraph 4.5.1, a formal parameter may be associated with more than one field of a body statement in which it is used, in which case the actual parameter that is substituted for it must contain delimiters. The less-than/greater-than character pair is used to enclose any actual parameter that contains internal delimiters. Thus, in the MACRO call:
4.6 Assembly Program Counter Control Statements
An ORG statement sets the assembly program counter to a specified value. The value specified in an ORG statement must be larger than the current value because setting the counter to a lesser value would result in overwriting of previously generated object code. The format of an ORG statement is:
expression is an expression which is evaluated to determine the setting of the assembly program counter
NOTE: The assembly program counter is automatically set to zero at the
start of the assembly phase program execution.
A RES statement causes a specified number to be added to the current assembly program count so as to reserve a block of memory locations.
The format of a RES statement is:
expression is evaluated to determine the number locations to be reserved
An ALIGN statement causes the assembly program counter to be advanced to the next value located on a specified boundary. The boundary is specified in terms of a factor of which the boundary is an integral multiple.
The format of an ALIGN statement is:
Expression is evaluated to determine the boundary factor.
4.7 Instruction/Data Source Statements
4.7.1 Formatted Instruction Statements
Formatted instruction statements generate executable microinstructions from instruction formats specified during the definition phase by DEF statements. Formatted instruction statements consist of one or more instruction format names followed by variable field substitution values. A value must be provided for each variable field for which no default value was specified. Optionally, a different value can be substituted for any of the default values.
Multiple instruction formats can be combined (overlaid) to form an executable microinstruction as long as each field is specified as a constant or variable field in only one of those formats; i.e., constant or variable fields can be overlaid on don’t care fields. In addition, by use of the overlay attribute (@), the value associated with this attribute can be overlaid on a part or all of a variable field in another format.
The format of a formatted instruction statement is:
/VFS1n {& name2 VFS21,…}../{& namen VSn1,..}
name1, name2, … namen are instruction format names,
VFS11, VFS12, VFS1n, are variable field substitution
values.
Ampersands (&) are delimiters preceding the second and succeeding instruction format names. This identifies the start of each instruction format to be overlaid on the preceding instruction formats.
Example 2: ALU.1 SEL,RA3,RB2,,AB,Y,YA,,B#1
In the example above, the overlay attribute was provided in the DEF statement for the ALU.2 and ALU.3 formats. If that DEF statement had not included the overlay attribute, the overlay could have been specified by appending the overlay attribute to the LIT field variable substitution value in the formatted instruction source statement, as follows:
/ADD@,4H#1,4H#2,16X,AB
FF statements are used to generate executable microinstructions without reference to instruction format or instruction sub-format names. This requires specification of a constant or don’t care value for every field of the instruction. Constant values may be numerical constants, constant names, set-parameter names, or expressions.
Since the FF statement generates an executable microinstruction, the sum of all the field widths must be equal to the microword width specified by the WORD statement in the definition file.
Optionally, a symbolic address label can be assigned in an FF statement.
The form of an FF statement is:
The DATA statement provides the means of setting up a data constant (literal) in a separate microword to be accesses under control of the executable instruction in a preceding microword. The format of a DATA statement is:
DATA is the statement operator,
expression is an expression whose value is placed in the microword.
The DUP statement is used to generate multiple lines of instructions or data. The DUP statement causes the instruction or data word on the line following the DUP statement to be repeated a specified number of times. The format is:
expression is an expression whose value determines the number of duplications
In a relocatable, assembly-phase source program, the .REL statement must be entered prior to the first statement which affects the assembly program counter. Thus, the .REL statement must be entered before any machine instruction source statement or any ORG statement.
The format of the .REL statement is:
An EXTRN statement is used to declare one or more symbols as external symbols. An external symbol is a symbol not defined in the definition file or in the current assembly phase source program but defined in another program file that is subsequently to be linked to this one. Any given symbol can only be listed in one EXTRN statement of a particular file. A symbol that is declared as EXTRN in one or more files must be listed in a PUBLIC statement in the file in which it is defined.
The format of an EXTRN statement is:
Example: EXTRN WRITE.B,READ.B
A PUBLIC statement makes the listed symbols available for declaration as EXTRN symbols in other assembly-phase source program files. To be declared PUBLIC, a symbol must be defined in the current assembly-phase source program file or in the definition file. Instruction format names, instruction sub-format names, and MACRO names cannot be declared PUBLIC. Symbolic address labels, constant names, and set-parameter names can be declared PUBLIC. A symbol can only be declared PUBLIC in one PUBLIC statement in any group of files that are to be linked.
The format of a PUBLIC statement is:
Example: PUBLIC WRITE.B,READ.B
An INCLUDE statement names a secondary source file. When the definition or assembly phase program reaches an INCLUDE statement, it processes the statements contained in the file named in the INCLUDE statement. In general, the statements in the secondary source file are processed in exactly the same manner as they would have been had they been listed in the primary file starting at the point where the INCLUDE statement is listed.
There are two exceptions to this:
2. The secondary source file is not permitted to contain any INCLUDE
statements. (NOTE: WinTim32 does not have this restriction).
The MAP statement is appropriate only in an absolute assembly-phase source program an is ignored if entered in a relocatable assembly-phase source program.
The entry point map object file consists of the addresses assigned to all entry point symbolic address labels. A symbolic address label is specified as an entry point by terminating the symbol field of the source statement with a double colon (::). For example, the formatted instruction source statement:
Entry point addresses are listed in the entry point map in the same order that they are assigned by the assembly-phase program. The format of the MAP statement is:
width is the width in bits of the entry point map object words (decimal)
000021 END2 0000A2
When the definition-phase or assembly-phase program encounters an END statement in a source file, it interprets this as the end of the file. If no END statement is encountered, the program will continue processing statements until the end of the source file is encountered. The format of the END statement is:
The DCARE statement is used in the assembly-phase source program to assign values to don’t care bits. If the assembly-phase program does not contain a DCARE statement, all don’t care bits are set to X. In this case any don’t care bit or any digit containing any don’t care bits will appear as an X in any object code listing and don’t care bits will be marked as such in the object file. Typically, this statement is used to assign either the value of 1 or the value of 0 to all don’t care bits of the module. In order to achieve this result, the DCARE statement must precede the first statement containing don’t care bits.
It is also possible, by use of more than one DCARE statement, to assign different values to don’t care bits in different segments of the program. Any don’t care bits in statements prior to the first DCARE statement will remain set to X. If the program contains more than once DCARE statement, the value assigned to don’t care bits in any statement will be the value specified in the DCARE statement which most closely precedes the statement containing the don’t care bits.
The format of the DCARE statement is: