Infineon Technologies C166S V2 User Manual page 86

16-bit microcontroller
Table of Contents

Advertisement

MAC Unit Status (MV, MN, MZ, MC, MSV, ME, MSL)
The condition flags (MV, MN, MZ, MC, MSV, ME, MSL) within the MSW indicate the
MAC resulting from the most recently performed MAC operation. These flags are
controlled by the majority of the MAC instructions according to specific rules. Those rules
depend on the instruction managing the MAC or data movement operation.
After execution of an instruction which explicitly updates the MSW register, the condition
flags may no longer represent an actual MAC status. An explicit write operation to the
MSW register supersedes the condition flag values implicitly generated by the MAC unit.
An explicit read access to the MSW register returns the value of the MSW register after
execution of the immediately preceding instruction. The MSW register can be accessed
via any instruction capable of accessing an SFR.
Note: After reset, all MAC status bits are cleared.
MSW
MAC Status Word
15
14
13
12
0
MV MSL ME MSV MC
rwh
rwh
rwh
r
Field
MAE
MN
MZ
MC
MSV
User Manual
SFRb
11
10
9
8
MZ
MN
rwh
rwh
rwh
rwh
Bits
Type Description
[7:0]
rwh
The most significant bits of the 40-bit Accumulator
[8]
rwh
Negative Result
0
1
[9]
rwh
Zero Flag
0
1
[10]
rwh
Carry Flag
0
1
[11]
rwh
Sticky Overflow Flag
0
1
7
6
5
MAC result is positive
MAC result is negative
MAC result is not zero
MAC result is zero
No carry/borrow produced
Carry/borrow produced
No Overflow occurred
Overflow occurred
2-86
User Manual
C166S V2
Central Processing Unit
Reset Value: 0000
4
3
2
1
MAE
rwh
V 1.7, 2001-01
H
0

Advertisement

Table of Contents
loading

Table of Contents