Statements
This section outlines the types of statements that apply to assembly language. Each
statement must be one of the following types:
4
An empty statement is one that contains nothing other than spaces, tabs, or
formfeed characters.
Empty statements have no meaning to the assembler. They can be inserted freely
to improve the appearance of a source file or of a listing generated from it.
4
An assignment statement is one that gives a value to a symbol. It consists of a
symbol, followed by an equal sign (=), followed by an expression.
The expression is evaluated and the result is assigned to the symbol. Assignment
statements do not generate any code. They are used only to assign assembly time
values to symbols.
4
A pseudo operation statement is a directive to the assembler that does not
necessarily generate any code. It consists of a pseudo operation code, optionally
followed by operands. Every pseudo operation code begins with a period (.).
4
A machine operation statement is a mnemonic representation of an executable
machine language instruction to which it is translated by the assembler. It consists
of an operation code, optionally followed by operands.
Furthermore, any statement remains a statement even if it is modified in either or
both of the following ways:
4
Prefixing a label at the beginning of the statement.
A label consists of a symbol followed by a colon (:). When the assembler
encounters a label, it assigns the value of the location counter to the label.
4
Appending a comment at the end of the statement by preceding the comment
with a slash (/).
The assembler ignores all characters following a slash up to the next occurrence of
newline. This facility allows insertion of internal program documentation into the
source file for a program.
Values and Symbol Types
This section presents the values and symbol types that the assembler uses.
Values
Values are represented in the assembler by numerals which can be faithfully
represented in standard two’s complement binary positional notation using 32 bits.
All integer arithmetic is performed using 32 bits of precision. Note, however, that the
values used in an x86 instruction may require 8, 16, or 32 bits.
Assembler Input 3