Panasonic MN103S User Manual page 516

Panaxseries
Hide thumbs Also See for MN103S:
Table of Contents

Advertisement

Chapter 16
Appendix
MCST (8-, 16- and 32-bit saturation instructions for multiply and accumulate result)
[Instruction format (macro name)]
MCST32, MCST16, MCST8
[Assembler mnemonic]
udf02 Dm, Dn
udf02 imm8, Dn
[Operation]
This instruction places the content of the multiply and accumulate overflow detection flag register MCVF in the V
flag. Note also that the instruction performs the following depending on the Dm value:
1. When Dm is 32 (0x00000020)
This instruction stores the 32-bit signed positive maximum value (0x7fffffff) and the 32-bit signed negative
maximum value (0x80000000) in Dn respectively when the 64-bit multiply and accumulate result, stored in
the multiply and accumulate registers MCRH and MCRL, is equal to or greater than the positive maximum
value (0x000000007fffffff) and equal to or smaller than the negative maximum value (0xffffffff80000000).
In any other case, the instruction stores the content of MCRL in Dn.
2. When Dm is 16 (0x00000010)
This instruction stores the 16-bit signed positive maximum value (0x00007fff ) and the 16-bit signed negative
maximum value (0xffff8000) in Dn respectively when the 64-bit multiply and accumulate result, stored in the
multiply and accumulate registers MCRH and MCRL, is equal to or greater than the positive maximum value
(0x0000000000007fff) and equal to or smaller than the negative maximum value (0xffffffffffff8000). In any
other case, the instruction stores the content of MCRL in Dn.
3. When Dm is 8 (0x00000008)
This instruction stores the positive maximum value (0x7f) and the negative maximum value (0x80) in Dn
respectively when the 32-bit multiply and accumulate result, stored in the multiply and accumulate register
MCRL, is equal to or greater than the 8-bit signed positive maximum value (0x0000007f) and equal to or
smaller than the 8-bit signed negative maximum value (0xffffff80). In any other case, the instruction stores the
content of MCRL in Dn.
4. When Dm is any other value
The value in Dn is undefined.
[Flag changes]
When multiply and accumulate overflow is not detected (MCVF = 0)
Flag
Change
V
0
C
0
N
*
Z
*
When multiply and accumulate overflow is detected (MCVF = 1)
Flag
Change
V
1
C
0
N
*
Z
*
[Note for programming]
Updating of the PSW as a result of flag changes is delayed by 1 instruction.
Note, however, that flags can be evaluated for the Bcc and Lcc instructions before flag changes are reflected in the
PSW.
XVI - 64
Extension Instruction Specification
: Only 0x20, 0x10 and 0x08 of the imm8 value are valid
Condition
Indicates that multiply and accumulate operation is valid.
Always "0".
Undefined
Undefined
Condition
Indicates that multiply and accumulate operation is invalid.
Always "0".
Undefined
Undefined

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mn103sa7dMn103sa7g

Table of Contents