Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
IMUL
◄Summary► ◄Detail► ◄Example► ◄Key to Flags►
──────────────────────────────────────────────────────────────────────────────
Signed Multiply Flags: O D I T S Z A P C
Syntax: IMUL src ═════════════════
± ? ? ? ? ±
Multiplies an implied destination operand by a specified source operand.
Both operands are treated as signed numbers. If a single 16-bit operand
is given, the implied destination is AX and the product goes into
the DX:AX register pair. If a single 8-bit operand is given, the
implied destination is AL and the product goes into AX. On the
80386, if the operand is EAX, the product goes into the EDX:EAX reg-
ister pair. The carry and overflow flags are set if the product is sign
extended into DX for 16-bit operands, into AH for 8-bit operands,
or into EDX for 32-bit operands.
Two additional syntaxes are available on the 80186-80386 processors. In
the two-operand form, a 16-bit register gives one of the factors and
serves as the destination for the result; a source constant specifies the
other factor. In the three-operand form, the first operand is a 16-bit
register where the result will be stored, the second is a 16-bit register
or memory operand containing one of the factors, and the third is a con-
stant representing the other factor. With both variations, the overflow and
carry flags are set if the result is too large to fit into the 16-bit des-
tination register. Since the low 16 bits of the product are the same for
both signed and unsigned multiplication, these syntaxes can be used for
either signed or unsigned numbers.
-♦-