Appendix A. Partial x86 Instruction Set Reference
Instruction | Reference Page | Text Page | CPU |
---|---|---|---|
AAA | 512 | 411 | |
ADC | 513 | Only in Appendix A | |
ADD | 515 | 207 | |
AND | 517 | 281 | |
BT | 519 | 306 | 386+ |
CALL | 521 | 336, 483 | |
CLC | 523 | Only in Appendix A | |
CLD | 524 | 411 | |
CMP | 525 | 411 | |
DEC | 527 | 215 | |
DIV | 528 | 411 | |
INC | 529 | 215 | |
INT | 530 | 411 | |
IRET | 531 | 260 | |
J? | 532 | 218, 299, 302 | |
JCXZ | 534 | 421 | |
JECXZ | 535 | Only in Appendix A | 386+ |
JMP | 536 | 298 | |
LEA | 537 | 315 | |
LOOP | 538 | 408 | |
LOOPNZ/LOOPNE | 540 | 422 | |
LOOPZ/LOOPE | 541 | Only in Appendix A | |
MOV | 542 | 204 | |
MOVS | 544 | 414 | |
MOVSX | 546 | 224 | 386+ |
MUL | 547 | 225 | |
NEG | 549 | 223 | |
NOP | 550 | Only in Appendix A | |
NOT | 551 | 285 | |
OR | 552 | 283 | |
POP | 554 | 251 | |
POPA | 555 | 251, 344 | 286+ |
POPAD | 555 | 251, 344 | 386+ |
POPF | 556 | 251 | |
POPFD | 557 | 251 | 386+ |
PUSH | 558 | 249 | |
PUSHA | 559 | 249 | 286+ |
PUSHAD | 560 | 249, 344 | 386+ |
PUSHF | 561 | 249 | |
PUSHFD | 562 | 249 | 386+ |
RET | 563 | 337 | |
ROL | 564 | 288 | |
ROR | 566 | 288 | |
SBB | 568 | Only in Appendix A | |
SHL | 570 | 286 | |
SHR | 572 | 286 | |
STC | 574 | 289 | |
STD | 575 | 405 | |
STOS | 576 | 402 | |
SUB | 577 | 302 | |
XCHG | 579 | 234 | |
XLAT | 580 | 321 | |
XOR | 581 | 284 |
Notes on the Instruction Set Reference
Instruction Operands
When an instruction takes two operands, the destination operand is the one on the left, and the source operand is the one on the right. In general, when a result is produced by an instruction, the result replaces the destination operand. For example, in the instruction
ADD BX,SI
the BX register is added to the SI register, and the sum is then placed in the BX register, overwriting whatever was in BX before the addition.
Flag Results
Each instruction contains a flag summary that looks like the following (the asterisks present will vary from instruction to instruction):
O D I T S Z A P C OF: Overflow flag TF: Trap flag AF: Aux carry F F ...
Get Assembly Language Step-by-Step: Programming with Linux®, Third Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.