ST10 FAMILY PROGRAMMING MANUAL
158/172
CoMULus(-)
Mixed Multiply & Optional Round
Group
Multiply/Multiply-Accumulate Instructions
Syntax
CoMULus op1,
op2
Operation
(ACC)
<-- (op1) * (op2)
Syntax
CoMULus- op1,
op2
Operation
(ACC)
<-- - ((op1) * (op2))
Syntax
CoMULus
op1, op2, rnd
Operation
(ACC)
<-- (op1) * (op2) + 00 0000 8000
h
(MAL) <--
0
Data Types
DOUBLE WORD
Result
32-bit signed value
Description
Multiply the two 16-bit unsigned and signed source operands “op1” and “op2”, respectively. The obtained
signed 32-bit product is first sign-extended, then it is optionally either negated or rounded before being
stored in the 40-bit ACC register. The result is never affected by the MP mode flag contained in the MCW
register. The “-” option is used to negate the specified product while the “rnd” option is used to round the
product using two’s complement rounding. The default sign option is “+” and the default round option is
“no round”. When “rnd” option is used, MAL register is automatically cleared. “rnd” and “-” are exclusive.
This non-repeatable instruction allows up to two parallel memory reads.
MAC Flags
Addressing Modes
N
Z
C
SV
E
SL
*
*
0
-
0
-
N
Set if the most significant bit of the result is set. Cleared otherwise.
Z
Set if the result equals zero. Cleared otherwise.
C
Always cleared.
SV
Not affected.
E
Always cleared.
SL
Not affected.
Mnemonic
Rep
Format
Bytes
CoMULus
Rw
n
, Rw
m
No
A3 nm 80 00
4
CoMULus-
Rw
n
, Rw
m
No
A3 nm 88 00
4
CoMULus
Rw
n
, Rw
m
, rnd
No
A3 nm 81 00
4
CoMULus
[IDX
i
⊗
], [Rw
m
⊗]
No
93 Xm 80 0:0qqq
4
CoMULus-
[IDX
i
⊗
], [Rw
m
⊗]
No
93 Xm 88 0:0qqq
4
CoMULus
[IDX
i
⊗
], [Rw
m
⊗]
, rnd
No
93 Xm 81 0:0qqq
4
CoMULus
Rw
n
, [Rw
m
⊗]
No
83 nm 80 0:0qqq
4
CoMULus-
Rw
n
, [Rw
m
⊗
]
No
83 nm 88 0:0qqq
4
CoMULus
Rw
n
, [Rw
m
⊗]
, rnd
No
83 nm 81 0:0qqq
4
Содержание ST10 Series
Страница 2: ......
Страница 4: ...ST10 FAMILY PROGRAMMING MANUAL 2 172...