3-73
INSTRUCTION SET REFERENCE
CMOVccConditional Move (Continued)
Description
The CMOVcc instructions check the state of one or more of the status flags in the EFLAGS
register (CF, OF, PF, SF, and ZF) and perform a move operation if the flags are in a specified
state (or condition). A condition code (cc) is associated with each instruction to indicate the
condition being tested for. If the condition is not satisfied, a move is not performed and execu-
tion continues with the instruction following the CMOVcc instruction.
These instructions can move a 16- or 32-bit value from memory to a general-purpose register or
from one general-purpose register to another. Conditional moves of 8-bit register operands are
not supported.
The conditions for each CMOVcc mnemonic is given in the description column of the above
table. The terms less and greater are used for comparisons of signed integers and the terms
above and below are used for unsigned integers.
Because a particular state of the status flags can sometimes be interpreted in two ways, two
mnemonics are defined for some opcodes. For example, the CMOVA (conditional move if
above) instruction and the CMOVNBE (conditional move if not below or equal) instruction are
alternate mnemonics for the opcode 0F 47H.
Opcode
Instruction
Description
0F 41 /r
CMOVNO r16, r/m16
Move if not overflow (OF=0)
0F 41 /r
CMOVNO r32, r/m32
Move if not overflow (OF=0)
0F 4B /r
CMOVNP r16, r/m16
Move if not parity (PF=0)
0F 4B /r
CMOVNP r32, r/m32
Move if not parity (PF=0)
0F 49 /r
CMOVNS r16, r/m16
Move if not sign (SF=0)
0F 49 /r
CMOVNS r32, r/m32
Move if not sign (SF=0)
0F 45 /r
CMOVNZ r16, r/m16
Move if not zero (ZF=0)
0F 45 /r
CMOVNZ r32, r/m32
Move if not zero (ZF=0)
0F 40 /r
CMOVO r16, r/m16
Move if overflow (OF=0)
0F 40 /r
CMOVO r32, r/m32
Move if overflow (OF=0)
0F 4A /r
CMOVP r16, r/m16
Move if parity (PF=1)
0F 4A /r
CMOVP r32, r/m32
Move if parity (PF=1)
0F 4A /r
CMOVPE r16, r/m16
Move if parity even (PF=1)
0F 4A /r
CMOVPE r32, r/m32
Move if parity even (PF=1)
0F 4B /r
CMOVPO r16, r/m16
Move if parity odd (PF=0)
0F 4B /r
CMOVPO r32, r/m32
Move if parity odd (PF=0)
0F 48 /r
CMOVS r16, r/m16
Move if sign (SF=1)
0F 48 /r
CMOVS r32, r/m32
Move if sign (SF=1)
0F 44 /r
CMOVZ r16, r/m16
Move if zero (ZF=1)
0F 44 /r
CMOVZ r32, r/m32
Move if zero (ZF=1)