Quick start manual
Inline assembly code
13-17
. Structure member selector. The result is the sum of the expression before the period
and the expression after the period, with the type of the expression after the period.
Symbols belonging to the scope identified by the expression before the period can be
accessed in the expression after the period.
HIGH Returns the high-order 8 bits of the word-sized expression following the operator.
The expression must be an absolute immediate value.
LOW Returns the low-order 8 bits of the word-sized expression following the operator. The
expression must be an absolute immediate value.
+ Unary plus. Returns the expression following the plus with no changes. The
expression must be an absolute immediate value.
– Unary minus. Returns the negated value of the expression following the minus. The
expression must be an absolute immediate value.
+ Addition. The expressions can be immediate values or memory references, but only
one of the expressions can be a relocatable value. If one of the expressions is a
relocatable value, the result is also a relocatable value. If either of the expressions is a
memory reference, the result is also a memory reference.
– Subtraction. The first expression can have any class, but the second expression must
be an absolute immediate value. The result has the same class as the first expression.
: Segment override. Instructs the assembler that the expression after the colon belongs
to the segment given by the segment register name (CS, DS, SS, FS, GS, or ES) before
the colon. The result is a memory reference with the value of the expression after the
colon. When a segment override is used in an instruction operand, the instruction is
prefixed with an appropriate segment-override prefix instruction to ensure that the
indicated segment is selected.
OFFSET Returns the offset part (double word) of the expression following the operator. The
result is an immediate value.
TYPE Returns the type (size in bytes) of the expression following the operator. The type of
an immediate value is 0.
PTR Typecast operator. The result is a memory reference with the value of the expression
following the operator and the type of the expression in front of the operator.
* Multiplication. Both expressions must be absolute immediate values, and the result
is an absolute immediate value.
/ Integer division. Both expressions must be absolute immediate values, and the result
is an absolute immediate value.
MOD Remainder after integer division. Both expressions must be absolute immediate
values, and the result is an absolute immediate value.
SHL Logical shift left. Both expressions must be absolute immediate values, and the result
is an absolute immediate value.
SHR Logical shift right. Both expressions must be absolute immediate values, and the
result is an absolute immediate value.
NOT Bitwise negation. The expression must be an absolute immediate value, and the
result is an absolute immediate value.
AND Bitwise AND. Both expressions must be absolute immediate values, and the result is
an absolute immediate value.
Table 13.7 Definitions of built-in assembler expression operators (continued)
Operator Description