23.6. Invalid Operation exception

An operation is invalid if the result cannot be represented, or if the result is not defined.

Table 23.4 shows the operand combinations that produce Invalid Operation exceptions. In addition to the conditions in Table 23.4, any CDP instruction other than FCPY, FNEG, or FABS causes an Invalid Operation exception if one or more of its operands is an SNaN (see Table 20.1).

Table 23.4. Possible Invalid Operation exceptions

InstructionInvalid Operation exceptions
FADD(+infinity) + (-infinity) or (-infinity) + (+infinity).
FSUB(+infinity) - (+infinity) or (-infinity) - (-infinity).
FCMPE/FCMPEZAny NaN operand
FMUL/FNMULZero  ±infinity or ±infinity  zero.[1]
FDIVZero/zero or infinity/infinity.a
FMAC/FNMACAny condition that can cause an Invalid Operation exception for FMUL or FADD can cause an Invalid Operation exception for FMAC and FNMAC. The product generated by the FMAC or FNMAC multiply operation is considered in the detection of the Invalid Operation exception for the subsequent sum operation.
FMSC/FNMSCAny of the conditions that can cause an Invalid Operation exception for FMUL or FSUB can cause an Invalid Operation exception for FMSC and FNMSC. The product generated by the FMSC or FNMSC multiply operation is considered in the detection of the Invalid Operation exception for the subsequent difference operation.
FSQRTSource is less than 0.
FTOUIRounded result would lie outside the range 0 ≤ result < 232.
FTOSIRounded result would lie outside the range -231 ≤ result < 231.

[1] In flush-to-zero mode, a subnormal input is treated as a positive zero for detecting an Invalid Operation exception.

Copyright © 2005-2007 ARM Limited. All rights reserved.ARM DDI 0290G
Non-Confidential