3-104
INSTRUCTION SET REFERENCE
COMISS—Scalar Ordered Single-FP Compare and Set EFLAGS
Description
The COMISS instruction compares two SP FP numbers and sets the ZF,PF,CF bits in the
EFLAGS register as described above. Although the data type is packed single-FP, only the lower
SP numbers are compared. In addition, the OF, SF, and AF bits in the EFLAGS register are
zeroed out. The unordered predicate is returned if either input is a NaN (qNaN or sNaN).
Figure 3-23. Operation of the COMISS Instruction, Condition One
EFLAGS: OF,SF,AF=000
EFLAGS: ZF,PF,CF=111
MXCSR flags: Invalid flag is set
OpcodeInstruction
Description
0F,2F,/rCOMISS xmm1,
xmm2/m32
Compare lower SP FP number in XMM1 register with lower SP
FP number in XMM2/Mem and set the status flags accordingly
=
=
=
=
Xmm1
Xmm2/
m32
Xmm1
COMISS xmm1, xmm2/m32