![Infineon Technologies XC2200 User Manual Download Page 195](http://html1.mh-extra.com/html/infineon-technologies/xc2200/xc2200_user-manual_2055439195.webp)
XC2200 Derivatives
System Units (Vol. 1 of 2)
Central Processing Unit (CPU)
User’s Manual
4-57
V2.1, 2008-08
CPUSV2_X, V2.2
ALU/MAC Status (N, C, V, Z, E, USR0, USR1)
The condition flags (N, C, V, Z, E) within the PSW indicate the ALU status after the most
recently performed ALU operation. They are set by most of the instructions according to
specific rules which depend on the ALU or data movement operation performed by an
instruction.
After execution of an instruction which explicitly updates the PSW register, the condition
flags cannot be interpreted as described below because any explicit write to the PSW
register supersedes the condition flag values which are implicitly generated by the CPU.
Explicitly reading the PSW register supplies a read value which represents the state of
the PSW register after execution of the immediately preceding instruction.
Note: After reset, all of the ALU status bits are cleared.
N-Flag:
For most of the ALU operations, the N-flag is set to 1, if the most significant bit
of the result contains a 1; otherwise, it is cleared. In the case of integer operations, the
N-flag can be interpreted as the sign bit of the result (negative: N = 1, positive: N = 0).
USR1
7
rwh
General Purpose Flag
May be used by application
USR0
6
rwh
General Purpose Flag
May be used by application
MULIP
5
r
Multiplication/Division in Progress
Note: Always set to 0 (MUL/DIV not interruptible),
for compatibility with existing software.
E
4
rwh
End of Table Flag
0
Source operand is neither 8000H nor 80H
1
Source operand is 8000H or 80H
Z
3
rwh
Zero Flag
0
ALU result is not zero
1
ALU result is zero
V
2
rwh
Overflow Flag
0
No Overflow produced
1
Overflow produced
C
1
rwh
Carry Flag
0
No carry/borrow bit produced
1
Carry/borrow bit produced
N
0
rwh
Negative Result
0
ALU result is not negative
1
ALU result is negative
Field
Bits
Type
Description