Hardware manual

Microcomputer Technical Q&A
4
Q&A No.: QAH8S-003
Category: CPU
Subject: Relationship between Data Size and Change of V Flag
Question
Do changes of the V flag in the condition code register (CCR) depend on the data size?
Answer
The V flag changes on detection of overflow in the result of a signed arithmetic operation. The
change operation is the same regardless of the data size, but the times when the flag changes differ
as shown below.
Byte size: In the case of a value larger than H'7F or smaller than H'80
Word size: In the case of a value larger than H'7FFF or smaller than H'8000
Longword size: In the case of a value larger than H'7FFFFFFF or smaller than H'80000000
Applicable Products
Applicability Series Applicability Series Applicability Series
Yes Entire H8S Series H8S/2655 H8S/2350
H8S/2355 H8S/2357 H8S/2345
H8S/2245 H8S/2148 H8S/2144
H8S/2138 H8S/2134 H8S/2128
H8S/2124