x86 Instruction Summary (by Gary M. Zoppetti) ======================= mov S, D D <-- S Move movz S, D D <-- ZeroExtend (S) Move zero extend (takes two suffixes: e.g., movzbl to extend a byte to a long) movs S, D D <-- SignExtend (S) Move sign extend (takes two suffixes: e.g., movsbl to extend a byte to a long) push S %esp <-- %esp - x Push M[%esp] <-- S (x is sizeof (S)) pop D D <-- M[%esp] Pop %esp <-- %esp + x (x is sizeof (S)) lea S, D D <-- S Load effective address inc D D <-- D + 1 Increment dec D D <-- D - 1 Decrement neg D D <-- -D Negate add S, D D <-- D + S Add sub S, D D <-- D - S Subtract imul S, D D <-- D * S Multiply idiv S %eax <-- %edx:%eax / S Divide %edx <-- %edx:%eax % S cltd %edx:%eax <-- SignExtend (%eax) Convert long to quad not D D <-- ~D Complement and S, D D <-- D & S And or S, D D <-- D | S Or xor S, D D <-- D ^ S Exclusive-or shl k, D D <-- D << k Shift left sar k, D D <-- D >> k Shift right (arithmetic) shr k, D D <-- D >> k Shift right (logical) cmp S, D Set condition codes Compare D:S test S, D Set condition codes Compute S & D (For setx, D is an 8-bit register and the source is a condition code) setz D D <-- ZF Set on zero setnz D D <-- ~ZF Set on not zero setc D D <-- CF Set on carry setnc D D <-- ~CF Set on no carry sets D D <-- SF Set on signed setns D D <-- ~SF Set on not signed seto D D <-- OF Set on overflow setno D D <-- ~OF Set on no overflow jmp label Jump (unconditional) jmp *label Jump indirect (unconditional) je label Branch on equal jne label Branch on not equal js label Branch on signed (negative) jns label Branch on unsigned (non-negative) jg label Branch on greater jge label Branch on greater or equal jl label Branch on less jle label Branch on less or equal