09.01.2013 Views

AMD x86-64 Architecture Programmer's Manual, Volume 4, 128-Bit ...

AMD x86-64 Architecture Programmer's Manual, Volume 4, 128-Bit ...

AMD x86-64 Architecture Programmer's Manual, Volume 4, 128-Bit ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>AMD</strong><strong>64</strong> Technology 26568—Rev. 3.05—September 2003<br />

COMISD Compare Ordered Scalar Double-Precision<br />

Floating-Point<br />

Compares the double-precision floating-point value in the low-order <strong>64</strong> bits of an<br />

XMM register with the double-precision floating-point value in the low-order <strong>64</strong> bits of<br />

another XMM register or a <strong>64</strong>-bit memory location and sets the ZF, PF, and CF bits in<br />

the rFLAGS register to reflect the result of the comparison. The result is unordered if<br />

one or both of the operand values is a NaN. The OF, AF, and SF bits in rFLAGS are set<br />

to zero.<br />

If the instruction causes an unmasked SIMD floating-point exception (#XF), the<br />

rFLAGS bits are not updated.<br />

Mnemonic Opcode Description<br />

COMISD xmm1, xmm2/mem<strong>64</strong> 66 0F 2F /r Compares double-precision floating-point values in an XMM<br />

register and an XMM register or <strong>64</strong>-bit memory location and sets<br />

rFLAGS.<br />

xmm1<br />

127 <strong>64</strong> 63 0<br />

compare<br />

Result of Compare ZF PF CF<br />

Unordered 1 1 1<br />

Greater Than 0 0 0<br />

Less Than 0 0 1<br />

Equal 1 0 0<br />

36 COMISD<br />

63<br />

0<br />

31<br />

rFLAGS<br />

127 <strong>64</strong> 63 0<br />

0<br />

xmm2/mem<strong>64</strong><br />

comisd.eps

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!