03.03.2013 Views

Intel® Architecture Instruction Set Extensions Programming Reference

Intel® Architecture Instruction Set Extensions Programming Reference

Intel® Architecture Instruction Set Extensions Programming Reference

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.

APPENDIX A<br />

OPCODE MAP<br />

Use the opcode tables in this chapter to interpret IA-32 and Intel 64 architecture object code. <strong>Instruction</strong>s are<br />

divided into encoding groups:<br />

• 1-byte, 2-byte and 3-byte opcode encodings are used to encode integer, system, MMX technology,<br />

SSE/SSE2/SSE3/SSSE3/SSE4, and VMX instructions. Maps for these instructions are given in Table A-2<br />

through Table A-6.<br />

• Escape opcodes (in the format: ESC character, opcode, ModR/M byte) are used for floating-point instructions.<br />

The maps for these instructions are provided in Table A-7 through Table A-22.<br />

NOTE<br />

All blanks in opcode maps are reserved and must not be used. Do not depend on the operation of<br />

undefined or blank opcodes.<br />

A.1 USING OPCODE TABLES<br />

Tables in this appendix list opcodes of instructions (including required instruction prefixes, opcode extensions in<br />

associated ModR/M byte). Blank cells in the tables indicate opcodes that are reserved or undefined.<br />

The opcode map tables are organized by hex values of the upper and lower 4 bits of an opcode byte. For 1-byte<br />

encodings (Table A-2), use the four high-order bits of an opcode to index a row of the opcode table; use the four<br />

low-order bits to index a column of the table. For 2-byte opcodes beginning with 0FH (Table A-3), skip any instruction<br />

prefixes, the 0FH byte (0FH may be preceded by 66H, F2H, or F3H) and use the upper and lower 4-bit values<br />

of the next opcode byte to index table rows and columns. Similarly, for 3-byte opcodes beginning with 0F38H or<br />

0F3AH (Table A-4), skip any instruction prefixes, 0F38H or 0F3AH and use the upper and lower 4-bit values of the<br />

third opcode byte to index table rows and columns. See Section A.2.4, “Opcode Look-up Examples for One, Two,<br />

and Three-Byte Opcodes.”<br />

When a ModR/M byte provides opcode extensions, this information qualifies opcode execution. For information on<br />

how an opcode extension in the ModR/M byte modifies the opcode map in Table A-2 and Table A-3, see Section A.4.<br />

The escape (ESC) opcode tables for floating point instructions identify the eight high order bits of opcodes at the<br />

top of each page. See Section A.5. If the accompanying ModR/M byte is in the range of 00H-BFH, bits 3-5 (the top<br />

row of the third table on each page) along with the reg bits of ModR/M determine the opcode. ModR/M bytes<br />

outside the range of 00H-BFH are mapped by the bottom two tables on each page of the section.<br />

A.2 KEY TO ABBREVIATIONS<br />

Operands are identified by a two-character code of the form Zz. The first character, an uppercase letter, specifies<br />

the addressing method; the second character, a lowercase letter, specifies the type of operand.<br />

A.2.1 Codes for Addressing Method<br />

The following abbreviations are used to document addressing methods:<br />

A Direct address: the instruction has no ModR/M byte; the address of the operand is encoded in the instruction.<br />

No base register, index register, or scaling factor can be applied (for example, far JMP (EA)).<br />

B The VEX.vvvv field of the VEX prefix selects a general purpose register.<br />

C The reg field of the ModR/M byte selects a control register (for example, MOV (0F20, 0F22)).<br />

Ref. # 319433-014 A-1

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

Saved successfully!

Ooh no, something went wrong!