103
4-12-3 Enhanced Math Instructions
The version-2 CVM1 CPUs provides symbol math instructions as an improve-
ment over the earlier BCD and binary math instructions. The basic data format
for these instructions is signed binary, although unsigned, BCD, and floating-
point data options can be specified. The functions of these instructions are
shown as symbols, making them easy to understand at a glance.
Most of these instructions are shown with a symbol and options. When the op-
tions are not included, the instruction will handle data as signed one-word binary
data without carry.
Symbol Data format options Carry option Data length option
+ (Add)
– (Subtract)
* (Multiply)
/ (Divide)
B (BCD)
U (Unsigned binary)
F (Floating point)
C (with carry) L (double)
The following table shows the function codes, mnemonics, and names of all of
the symbol math instructions. For details, refer to
5-20
Symbol Math Instruc-
tions
.
Code Mnemonic Name
400 + SIGNED BINARY ADD WITHOUT CARRY
401 +L DOUBLE SIGNED BINARY ADD WITHOUT CARRY
402 +C SIGNED BINARY ADD WITH CARRY
403 +CL DOUBLE SIGNED BINARY ADD WITH CARRY
404 +B BCD ADD WITHOUT CARRY
405 +BL DOUBLE BCD ADD WITHOUT CARRY
406 +BC BCD ADD WITH CARRY
407 +BCL DOUBLE BCD ADD WITH CARRY
410 – SIGNED BINARY SUBTRACT WITHOUT CARRY
411 –L DOUBLE SIGNED BINARY SUBTRACT WITHOUT CARRY
412 –C SIGNED BINARY SUBTRACT WITH CARRY
413 –CL DOUBLE SIGNED BINARY SUBTRACT WITH CARRY
414 –B BCD SUBTRACT WITHOUT CARRY
415 –BL DOUBLE BCD SUBTRACT WITHOUT CARRY
416 –BC BCD SUBTRACT WITH CARRY
417 –BCL DOUBLE BCD SUBTRACT WITH CARRY
420
*
SIGNED BINARY MULTIPLY
421
*L
DOUBLE SIGNED BINARY MULTIPLY
422
*U
UNSIGNED BINARY MULTIPLY
423
*UL
DOUBLE UNSIGNED BINARY MULTIPLY
424
*B
BCD MULTIPLY
425
*BL
DOUBLE BCD MULTIPLY
430 / SIGNED BINARY DIVIDE
431 /L DOUBLE SIGNED BINARY DIVIDE
432 /U UNSIGNED BINARY DIVIDE
433 /UL DOUBLE UNSIGNED BINARY DIVIDE
434 /B BCD DIVIDE
435 /BL DOUBLE BCD DIVIDE
Using Version-2 CVM1 CPUs Section 4-12